Results 1 to 2 of 2

Thread: Pop Up Menu in Dreamweaver 8 not displaying

  1. #1
    Join Date
    Feb 2009
    Location
    Romsey, UK
    Posts
    9
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Pop Up Menu in Dreamweaver 8 not displaying

    Hi guys,

    Now that I've finally figured out how to make a pop up menu in Dreamweaver (turns out it was not that hard) I have come across a new problem.

    I discovered these will not work in templates, so I decided to make an editable region in the template where I wanted the button to go and just added the button in manually to each page.

    Offline, running from my computer this works beautifully, the pop up menu performs and everything looks great.

    However, online, after uploading to my host it just works like a regular button with no pop up feature? Any ideas what could be preventing this from working? I used the pop up menu option in Dreamweaver 8, the code for the menu is:

    <script type="text/JavaScript">
    <!--
    function mmLoadMenus() {
    if (window.mm_menu_0206230659_0) return;
    window.mm_menu_0206230659_0 = new Menu("root",146,26,"Verdana, Arial, Helvetica, sans-serif",12,"#333333","#333333","#FFFFFF","#BCBCBC","left","middle",3,0,1000,-5,7,true,false,true,0,false,false);
    mm_menu_0206230659_0.addMenuItem("Body&nbsp;Butter","location='bodycarebutteronly.html'");
    mm_menu_0206230659_0.addMenuItem("Shower&nbsp;Gel","location='bodycareshowergelonly.html'");
    mm_menu_0206230659_0.addMenuItem("Cream/Lotion/Milk","location='bodycarecreamlotionmilk.html'");
    mm_menu_0206230659_0.addMenuItem("All&nbsp;Items","location='bodycare.html'");
    mm_menu_0206230659_0.hideOnMouseOut=true;
    mm_menu_0206230659_0.bgColor='#555555';
    mm_menu_0206230659_0.menuBorder=1;
    mm_menu_0206230659_0.menuLiteBgColor='#FFFFFF';
    mm_menu_0206230659_0.menuBorderBgColor='#777777';

    mm_menu_0206230659_0.writeMenus();
    } // mmLoadMenus()

    function MM_swapImgRestore() { //v3.0
    var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
    }

    function MM_preloadImages() { //v3.0
    var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
    }

    function MM_findObj(n, d) { //v4.01
    var p,i,x; if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
    if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
    for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
    if(!x && d.getElementById) x=d.getElementById(n); return x;
    }

    function MM_swapImage() { //v3.0
    var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
    if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
    }
    //-->
    </script>
    <script language="JavaScript" src="mm_menu.js"></script>
    </head><body onLoad="MM_preloadImages('images/Bodybuttonroll.jpg')">
    <script language="JavaScript1.2">mmLoadMenus();</script>
    <a href="bodycare.html" onMouseOut="MM_swapImgRestore();MM_startTimeout()" onMouseOver="MM_swapImage('BodyCarepop','','images/Bodybuttonroll.jpg',1);MM_showMenu(window.mm_menu_0206230659_0,146,0,null,'BodyCarepop')"><img src="images/Bodybutton.jpg" alt="Body Care Range" name="BodyCarepop" width="146" height="26" border="0"></a>
    Last edited by AlastairI; 02-07-2009 at 12:11 PM.

  2. #2
    Join Date
    Feb 2009
    Location
    Romsey, UK
    Posts
    9
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Hah! How stupid do I feel, I forgot to upload the .js file that was created for the menu to my host.

    So, um, problem solved

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •