Recent Questions
Q: I need current page highlighted on javascripts tab menu.
what I do the change on data.js file.
A: Deluxe Tabs doesn't support API functions which can return theselected tab aslo.
You can set "bselectedItem" and " var bselectedSmItem" parametersbased on your link before you call your data file.
For example, move " var bselectedItem" and " var bselectedSmItem" parametersfrom your data file to your code.
<TD vAlign=top align=left>
/* Select Tab */
<script type="text/javascript" language="JavaScript1.2">
var bselectedItem=<?php echo $seltabs; ?>;
var bselectedSmItem=<?php echo $selsmtabs; ?>;
</script>
<SCRIPT src="data.js" type=text/javascript></SCRIPT>
</TD>
You should define seltabs and selsmtabs using server side script.
You can also set it on every page before you call data.js file, forexample:
<TD vAlign=top align=left>
/* Select Tab */
<script type="text/javascript" language="JavaScript1.2">
var bselectedItem=4;
var bselectedSmItem=3;
</script>
<SCRIPT src="data.js" type=text/javascript></SCRIPT>
</TD>
Q: I tried the following for subitem and it worked but not working with the "Title item" (Group or header item), is there a way to process onclick for the title item? Thanks again.
You're able to use Javascript for each item, for example:
var tmenuitems = [
["item text", "javascript:your_code_here"]
];
A: Unfortunately, title items doesn't allow to use Javascript in the sameway.
But you can do the following:
var tmenuitems = [
["<div onclick='your_code_here'>title text</div>"]
];
Q: The submenu should look identical to the main menu but it is not allowing this.
Even though parameters are set to 0 it is showing smart scroll and also not showing the sub menus how they should be.
I also notice and error in the templates window view when I am looking at the javascript onmouseover menu.
A: You've set the exact width for your submenus:
var smHeight="21px"; // it is the height of the whole submenu
It is not right.
Try to write:
var smHeight="";
> I also notice and error in the templates window view when I am looking
> at the menu.
Now you have:
var pressedItem="";
It is not correct. Try to set:
var pressedItem="-2";
See the attached example.
Q: How do you center the text within the top-level menu cels in the menu java script?
There doesn't seem to be a setting for it in the tuner. There's a justification option for the sub-menus, but not for the top.
A: Use the following parameter to specify align for the top items:
var itemAlignTop="center";