Recent Questions Create Dynamic Tree From Oracle Database
Q: I have setup some tabs on a site that I am designing and for some reason when i click on a tab and it links to another page it automatically highlights the first tab in the row.
I have triedfiddling with it and have not been able to figure it out. Can someone point me in the right direction to have the correct tab selected in the css tab menu after i click it and goto the page.
A: Deluxe Tabs doesn't support API functions which can return theselected tab.
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>
</span>
Q: I have looked and looked but I cannot figure out for the life of me how to make the Icon ontop and the words on the bottom of java menu items, The class A and Class C words need to be at the bottom of the pictures if possible.
A: You can paste any html code within java menu items.
For example:
["<img src='image.gif'> <br>Class A ","","","",""]
Q: What I mean is I still want the destination page to be static inthe var menuitems but when the javascript side menu item is clicked, it'll run a js on the onclick or mouseup event.
Is this possible?
something like:
var menuItems = [
["text", "home", "javascript:onclick=your_code_here"]
];
A: You can achieve this by using standard html objects within javascript side menu items, for example:
var menuitems = [
["<div onContextMenu='your_code_here'>item text</div>", ""]
];
Actually you can use any html code within menuItems.
Q: How can I place the dhtml pull down menu onto multiple pages using FrontPage 2000? I am not using CSS. Do I need to copy the html into all of the pages, or just place the script into each page?
A: Yes, you should paste the following html code on your pages:
<noscript><a href="http://deluxe-menu.com">Javascript Menu by Deluxe-Menu.com</a></noscript>
<script type="text/javascript" language="JavaScript1.2" src="dmenu.js"></script>
...
<script type="text/javascript" language="JavaScript1.2" src="data.js"></script>
If you don't want to add such code on each page, you can try to useframes, the dhtml pull down menu has a cross-frame mode. Also you can use aserver-side script (php, asp, vb, etc.) to generate html pages fromtemplates on your server.