|
|
DHTML Side Menu Individual Item Styles
|
Individual Item Styles
|
|
Individual item styles are special dhtml menu parameters (arrays) that you can assign to each item of the javascript menu.
Using these styles you can create any menu you like.
var itemStyles = [
["paramName=value", "paramName=value", "paramName=value", ...], // style with index 0
["paramName=value", "paramName=value", "paramName=value", ...], // style with index 1
...
];
Each item style can use the following item parameters:
paramName=value |
Description |
itemWidth=100px |
Width of an item (px, % or other units). |
itemBackColor=#FFFFF,#000000 |
Normal and mouseover background colors. |
itemBorderWidth=1 |
Width of an item border. |
itemBorderStyle=solid,dotted |
Normal and mouseover border styles.
Available values: "none", "solid", "double", "dotted", "dashed", "groove", "ridge".
|
itemBorderColor=#AA0000,#0000EE |
Normal and mouseover border colors. |
fontStyle=normal 11px Tahoma |
Font style. |
fontColor=#000000,#FFFFFF |
Normal and mouse over font colors. |
fontDecoration=none,underline |
Normal and mouse over font decorations.
Available values: "none", "underline", "line-through", "overline".
|
itemBackImage=image1,image2 |
Normal and mouseover background images. |
arrowImageMain=image1,image2 |
Normal and mouseover arrows for a top-level item. |
arrowImageSub=image1,image2 |
Normal and mouseover arrows for a submenu item. |
CSS=classNormal,classOver |
Normal and mouseover CSS class names.
Works if var cssStyle=1; in menu parameters.
|
CSSText=classNormal,classOver |
Normal and mouseover CSS class names for a text.
Works if var cssStyle=1; in menu parameters.
|
|
After you created item styles you can assign them to dhtml side menu items.
For example:
var itemStyles = [
["itemWidth=150", "itemBackColor=#AA4400,#FF6600", "fontDecoration=none,underline"], // style 0
["itemBorderWidth=2", "itemBorderStyle=solid,solid", "itemBorderColor=#AA0000,#0000FF"], // style 1
["fontStyle=bold 12px Arial,Helvetica", "fontDecoration=none,underline"], // style 2
];
var menuItems = [
["Home", "index.html", "myicon1.gif", "myicon2.gif", "Home Page Tip", "_self", "2"], // assign style 2
["About", "about.html", "myicon3.gif", "myicon4.gif", "About Us Tip", "_self", "0"], // assign style 0
["Write Us", "mailto:mymail@mymail.com", "", "", "Write Us Tip", "", "1"], // assign style 1
];
Use DHTML Tuner application to create and assign individual item styles.
See also:
Menu Items
Individual Submenu Styles
|