Milonic provide full featured pull down web menus for some of the worlds largest companies
click here to see what it can do for you

Download Milonic DHTML Menu
Buy Milonic DHTML Menu

Back To Start Of Archive
Taken From The Forum: Help & Support for DHTML Menu Version 5+
Forum Topic: Click to view post
Last Updated: Saturday July 14 2012 - 06:07:01

Dragable Menu script still is not working.


Poster: Rickstre
Dated: Tuesday December 14 2004 - 2:25:34 GMT

navbar_milonic.js.php:
Code:
<?php
?><script type="text/javascript" src="/common/milonic_src.js"></script>   
<param copyright="JavaScript Menu by Milonic - http://www.milonic.com"></param>

<script   type="text/javascript">
<!--
if(ns4)_d.write("<scr"+"ipt language=JavaScript src=/common/mmenuns4.js><\/scr"+"ipt>");      
  else _d.write("<scr"+"ipt language=JavaScript src=/common/mmenudom.js><\/scr"+"ipt>");
-->
</script>

<script language=javascript>
<?php

include($_SERVER['DOCUMENT_ROOT']."/libs/navbars/menu_data.js.php");
   milonic_spewmenudatajs();
?>
</script>

<script type="text/javascript" src="/common/dragdrop.js"></script>

<script language="JavaScript1.2" type="text/javascript" src="/common/preloadmenuimages.js"></script>

First portion of menu_data.js.php (documentation of draggable menus says type=header;dragable=1)
Code:
<?php
// menu_data.js.php - milonic menu dyna javascript creator stuff
// changes: encapsulate the js generation code in a function, to avoid over-writing such global variables and things from included scripts.
   
function milonic_spewmenudatajs()
{
...
... (a bunch more of PHP code DB queries and variable definitions)
...
?>

_menuCloseDelay=500               // The time delay for menus to remain visible on mouse out
_menuOpenDelay=150                // The time delay before menus open on mouse over
_subOffsetTop=2                  // Sub menu top offset
_subOffsetLeft=-2                  // Sub menu left offset

with(XPMainStyle=new mm_style()){
onbgcolor="#C1D2EE";
oncolor="#000080";
offbgcolor="transparent";
offcolor="#000080";
bordercolor="#8A867A";
borderstyle="solid";
borderwidth=1;
separatorcolor="#8A867A";
separatorpadding="2";
separatoralign="right";
separatorwidth="80%";
headercolor='#000080';
padding=5;
openonclick=<?=($click)?>;
fontsize="<?=($fontsize)?>%";
fontstyle="normal";
fontweight="normal";
fontfamily="Verdana,Helvitica,Tahoma";
image="/images/xpblank.gif";
subimage="/images/arrow.gif";
onborder="1px solid #316AC5";
menubgimage="/images/winxp.gif";
}


with(XPMenuStyle=new mm_style()){
onbgcolor="#C1D2EE";
oncolor="#000080";
offbgcolor="transparent";
offcolor="#000080";
bordercolor="#8A867A";
borderstyle="solid";
borderwidth=1;
separatorcolor="#8A867A";
separatorpadding="2";
separatoralign="right";
separatorwidth="80%";
headercolor='#000080';
padding=5;
openonclick=<?=($click)?>;
fontsize="<?=($fontsize)?>%";
fontstyle="normal";
fontweight="normal";
fontfamily="Verdana,Helvitica,Tahoma";
image="/images/xpblank.gif";
subimage="/images/arrow.gif";
onborder="1px solid #316AC5";
menubgimage="/images/winxp.gif";
}

// MAIN MENU

with(milonic=new menuname("Main Menu")){
style=XPMainStyle;
top=10;
left=<?=($left)?>;
alwaysvisible=1;
followscroll=<?=($scroll)?>;

itemwidth="<?=($itemwidth)?>px"
margin=2;

<?  // Header of Main Menu
?>

aI("text=&nbsp;<?=($authuser[FirstName])?>;fontweight=bold;type=header;dragable=1;headerbgcolor=#d6d6ce;image=/images/navbar_header.gif;separatorsize=1;");

<?  // Back to home,
?>
aI("text=Support Home;url=/techs/index.php;status=Go back to <?=($authuser[FirstName])?>'s Support Home page;image=/images/navbar_<?=$ts[nav_icon_home]?>.gif;separatorsize=1;");
...
...(more menu items)
...
}
drawMenus();

<?php } ?>

dragdrop.js is in /common/ and no PHP or JS errors ensue. Menu works correctly in all other ways...

Yet it does not drag... Any ideas?

Rick


Poster: Ruth
Dated: Tuesday December 14 2004 - 18:19:35 GMT

Someone else just posted on this issue and the response was that the dragdrop file needed to be updated and this link was given http://www.milonic.net/dragdrop.js Hope that does it.

Ruth


Poster: Rickstre
Dated: Tuesday December 14 2004 - 22:14:08 GMT

Yes... I saw that post. I downloaded the file and no change. Do you see anything in the code that could cause the problem?

Rick


Poster: Ruth
Dated: Wednesday December 15 2004 - 2:37:06 GMT

I'm sorry, I don't know anything about coding. If you can change the title you might make it draggable still not working, and I'll see if I can notify someone.

Ruth


Poster: Rickstre
Dated: Thursday December 16 2004 - 17:35:34 GMT

I just fixed it myself by removing "type=header" and replacing it with type=dragable. Odd that the documentation does not seem to reflect this but rather seems to say that it MUST be a header.