Recent Questions
Q: I still do not understand your answer about the simple java menu arrows, which work in preview, but not on the website. The html is correct.
A: You have
var arrowImageMain=["ss.files/arrow_sub5.gif","ss.files/arrow_sub5.gif"];
in your data js, so the arrows must be here
http://domain/ss.files/arrow_sub5.gif
you arrows is here
http://domain/menu/ss.files/arrow_sub5.gif
You can use
var pathPrefix_img="menu/";
or change paths here
var arrowImageMain=["ss.files/arrow_sub5.gif","ss.files/arrow_sub5.gif"]; --> menu/ss.files/arrow_sub5.gif
Q: Can I put the icon on the left hand side of the text or does it have to be the right in the tree menu script?
A: You can put the icon as you wish on the left or right side.
You may set a alignment of icons and arrows.
To set them use these parameters:
var ticonAlign="right";
var texpandBtnAlign="right";
To set alignment of the top items in XP-style use:
var tXPAlign="right";
Q: Can you please give me tips on how I can style all menuitems to have font bold when selected and normal font when not selected?
A: Unfortunately, Deluxe Tree doesn't have such a feature. You can onlyset it's color. You cannot set the font of menu item bold when selected.
You can set menu item's font bold onMouseover, see example here:
http://deluxe-tree.com/data-templates/vista-style-7-template-sample.html
You should addthe following code in your data file:
function changeFont(obj, over)
{
obj.style.fontWeight = over ? 'bold' : 'normal';
obj.style.fontSize = over ? '13px' : '12px'; // You can not use this line
}
var tmenuItems = [
["<div onMouseOver='changeFont(this, 1)' onMouseOut='changeFont(this, 0)'>Security</div>","", "", "", "", "", "", "", "", ],
["<div onMouseOver='changeFont(this, 1)' onMouseOut='changeFont(this, 0)'>Ease of Access</div>","", "", "", "", "", "", "", "", ],
["|<div onMouseOver='changeFont(this, 1)' onMouseOut='changeFont(this, 0)'>Internet Options</div>","", "", "", "", "", "", "", "", ],
["|<div onMouseOver='changeFont(this, 1)' onMouseOut='changeFont(this, 0)'>Windows Firewall</div>","", "", "", "", "", "", "", "", ],
["<div onMouseOver='changeFont(this, 1)' onMouseOut='changeFont(this, 0)'>Network and Internet</div>","", "", "", "", "", "", "", "", ],
["<div onMouseOver='changeFont(this, 1)' onMouseOut='changeFont(this, 0)'>Hardware</div>","", "", "", "", "", "", "", "", ],
["<div onMouseOver='changeFont(this, 1)' onMouseOut='changeFont(this, 0)'>Programs</div>","", "", "", "", "", "", "", "", ],
["<div onMouseOver='changeFont(this, 1)' onMouseOut='changeFont(this, 0)'>Appearance</div>","", "", "", "", "", "", "", "", ],
["|<div onMouseOver='changeFont(this, 1)' onMouseOut='changeFont(this, 0)'>User Accounts</div>","", "", "", "", "", "", "", "", ],
["|<div onMouseOver='changeFont(this, 1)' onMouseOut='changeFont(this, 0)'>Personalization</div>","", "", "", "", "", "", "", "", ],
["<div onMouseOver='changeFont(this, 1)' onMouseOut='changeFont(this, 0)'>Sound and Speech</div>","", "", "", "", "", "", "", "", ],
["<div onMouseOver='changeFont(this, 1)' onMouseOut='changeFont(this, 0)'>Additional Options</div>","", "", "", "", "", "", "", "", ],
];
Please, notice also that you should add this function every time whenyou change your menu in Deluxe Tuner application, as Tuner deletesthis function.
Q: Both arrow types are visible when my intranet first loads and when I select a top item that is a direct link to a page.
But, as soon as I select any item from a list of sub items that includes subitems with arrows,
the arrow images disappear from vertical menu until I refresh the site.
A: You can use additional parameters to make menu paths absolute:
var pathPrefix_img = "http://domain.com/images/";
var pathPrefix_link = "http://domain.com/pages/";
These parameters allow to make images and links paths absolute.
For example:
var pathPrefix_img = "http://domain.com/images/";
var pathPrefix_link = "http://domain.com/pages/";
var menuItems = [
["text", "index.html", "icon1.gif", "icon2.gif"],
];
So, link path will be look so:
http://domain.com/pages/index.html
Images paths will be look so:
http://domain.com/images/icon1.gif
http://domain.com/images/icon2.gif
Please, try to use these parameters.