Recent Questions
Q: Can I expand all tree category, or expand two tree category?
I like your javascript menu expand product.
A: You can expand all items in Deluxe Tree, set:
var texpanded=1;
To expand specific items you should add "+" sign before item's text:
["+Samples Gallery","", "", "", "", "XP Title Tip", "", "1", "0", "", ],
["|+Samples Block 1","", "default.files/icon3_s.gif", "default.files/icon3_so.gif", "", "", "", "", "", "", ],
["||New Sample 1","testlink.htm", "default.files/iconarrs.gif", "", "", "", "", "", "", "", ],
["||New Sample 2","testlink.htm", "default.files/iconarrs.gif", "", "", "", "", "", "", "", ],
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: Is there a parameter in Tree Menu I can add and/or adjust in data.js toforce the menu text to wrap and add here to a set menu width?
A: You should use
tags, for example:
var tmenuItems = [
["line 1
line 2"],
];
Width of the menu you can set so:
var tmenuWidth = "500px";
Try that.
Try to specify units in "px".
var tmenuWidth = "182px";
It's necessary to specify exact value for Mozilla browsers. It helpsto position menus correctly.
You should set this parameter:
var tmenuHeight = "auto";
Q: I like “popup-mode-sample” but I could make it to work on my computer.
? Could you help?
A: If your menu doesn't work you should check paths to your dmenu.js file andto dmWorkPath parameter.