Recent Questions Dynamic Tree Menu Sidebar Javascript Php
Q: Working with dhtml tab menu, how do you place content under them?
A: You should paste your content in the <div> .. </div> tags.
<div id="content1" style=" visibility: hidden;" class="tabPage">
<p align=center><img src="img/logo_DM.gif" width=262 height=56 alt="Deluxe-Menu.com"></p>
</div>
<div id="content2" style="visibility: hidden;" class="tabPage">
<p align=center><img src="img/logo_DT.gif" width=262 height=56 alt="Deluxe-Tree.com"></p>
</div>
<div id="content3" style=" visibility: hidden;" class="tabPage">
<p align=center>>img src="img/logo_DTabs.gif" width=254 height=58 alt="Deluxe-Tabs.com"></p>
</div>
Q: I need to work it with PHP/MySQL. I have found some information on it in your Support section, but have problems to understand and wonder if you have more information or a working sample of the loading bar with PHP/ MySQL.
A: Info about generating menu (menu items )from a database, please, see:
http://deluxe-menu.com/generate-menu-from-database-xml-php-asp-vb-support.html
Please, see the example of .php file.
The content of .php file depends on your database structure.
<?php
// The example for PHP/MySQL.
// MySQL database has the table "menuTable" that contains data for menu items.
// The table has the following fields:
// 1. "text" - item text
// 2. "link" - item link
// 3. "icon1" - item icon (normal state)
// 4. "icon2" - item icon (mouseover state)
function getMenuItems()
{
$jsItems = '';
// Select all records from table "menuTable"
$allItems = mysql_query('SELECT * FROM menuTable;');
// Extract items data from database and build Javascript code for menuItems
while ($itemData=mysql_fetch_array($allItems))
{
$jsItems .= '["'.$itemData['text'].'", "'.$itemData['link'].'", "'.$itemData['icon1'].'", "'.$itemData['icon2'].'"],';
}
// Return Javascript code
return $jsItems;
}
?>
<script>
var menuParam1 = value1;
var menuParam2 = value2;
var menuParam2 = value2;
...
var menuItems = [
<?php
// Write Javascript code for menu items
echo getMenuItems();
?>
];
</script>
Q: When I add the menu to sites which are using ASP script the font color doesn't change when I roll over the menu, can you please have a look for me and explain whats up.
A: You're using CSS for your web pages.
You have set the font-color for the <TD> tag in an css style sheet file to #ed9c33.
Notice you should use CSS-based menu (CSS mode) if you're using CSSfor your TD tags (and for other objects).
Q: Using the example menu you have, how do i make the sub-menu for the 'Sample' menu item a multi-column and leave the 'Product Info' menu item as is.
I only want certain sub-menus to have multi-columns. I don't want all menu items to have a multi-column sub.
A: Please, see the attached example.
You should use individual styles.
var menuStyles = [
["smColumns=2"],
["smColumns=1"], //style 1
];
...
["More Samples","testlink.htm"],
["|Group 1","", , , , , "3", "1", , ], //assign style 1
Try that.