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:23

using Target=_blank links with buildlistmenu


Poster: earthmanweb
Dated: Thursday January 24 2008 - 5:28:49 GMT

Is it possible to target in a new windows using list based menu? You will notice in the source code that many of the links in the UL of menu items have a target="_blank" attribute, but are continuing to open in the same window. I am using the ListMenu version...

My test site is here:

http://dev2.########.com/

here is my buildlistmenu.js contents:

Code:
fixMozillaZIndex=false; //Fixes Z-Index problem  with Mozilla browsers but causes odd scrolling problem, toggle to see if it helps
_menuCloseDelay=500;
_menuOpenDelay=170;
_subOffsetTop=2;
_subOffsetLeft=-2;
buildAfterLoad=true;

with(menuStyle=new mm_style()){
onclass="menuStyle";
offclass="menuStyle";
bordercolor="";
borderstyle="";
borderwidth=0;
fontfamily="Verdana, Tahoma, Arial";
fontsize="12px";
fontstyle="normal";
headerbgcolor="";
headercolor="";
offbgcolor="";
offcolor="#FFFFFF";
onbgcolor="";
oncolor="#FF9";
padding=6;
pagebgcolor="";
pagecolor="#FF9";
separatorcolor="#CCCCCC";
separatorsize=1;
subimage="";
subimagepadding=2;
}

with(menuStyle2=new mm_style()){
onclass="menuStyle2";
offclass="menuStyle2";
bordercolor="";
borderstyle="";
borderwidth=0;
fontfamily="Verdana, Tahoma, Arial";
fontsize="100%";
fontstyle="normal";
headerbgcolor="";
headercolor="#000000";
offbgcolor="";
offcolor="#000000";
onbgcolor="";
oncolor="#EF7B0F";
padding=4;
pagebgcolor="";
pagecolor="";
separatorcolor="#CCCCCC";
separatorsize=1;
subimage="templates/includes/milonic/arrow.gif";
subimagepadding=2;

}

with(menuStyle3=new mm_style()){
onclass="menuStyle3";
offclass="menuStyle3";
bordercolor="";
borderstyle="";
borderwidth=0;
fontfamily="Verdana, Tahoma, Arial";
fontsize="100%";
fontstyle="normal";
headerbgcolor="";
headercolor="#000000";
offbgcolor="";
offcolor="#000000";
onbgcolor="";
oncolor="#EF7B0F";
padding=4;
pagebgcolor="";
pagecolor="black";
separatorcolor="#CCCCCC";
separatorsize=1;
subimage="templates/includes/milonic/arrow.gif";
subimagepadding=2;
}

with(menuStyle4=new mm_style()){
onclass="menuStyle3";
offclass="menuStyle3";
bordercolor="";
borderstyle="";
borderwidth=0;
fontfamily="Verdana, Tahoma, Arial";
fontsize="100%";
fontstyle="normal";
headerbgcolor="";
headercolor="#000000";
offbgcolor="";
offcolor="#000000";
onbgcolor="";
oncolor="#EF7B0F";
padding=4;
pagebgcolor="";
pagecolor="black";
separatorcolor="#CCCCCC";
separatorsize=1;
subimage="templates/includes/milonic/arrow.gif";
subimagepadding=2;
}


// syntax: buildListMenu("id of list", "menu style name", "main menu properties")
buildListMenu("milonicmenu1","menuStyle","alwaysvisible=true;orientation='horizontal';position='relative';");


Thanks!
Terran

Re: using Target=_blank links with buildlistmenu


Poster: Andy
Dated: Thursday January 24 2008 - 21:36:06 GMT

Hi,

Every email we send to bluemandala.com is bouncing with a "user not found" error, this is why you are not getting any email from us.

Anyway, I have changed the listmenus.js file and if you update your copy with the one from http://www.milonic.com/listmenus.js it should start using the target that you specify in the markup.

HTH,
Andy

Re: using Target=_blank links with buildlistmenu


Poster: earthmanweb
Dated: Friday January 25 2008 - 3:32:22 GMT

Hi Andy,

Thanks, it must be the spam filter for some reason. My apologies too, i just realized that I registered it under my other email address info at earthman dot ca. Sorry for the confusion!


I will try what you say and let you know how it goes...

Terran

Re: using Target=_blank links with buildlistmenu


Poster: earthmanweb
Dated: Wednesday January 30 2008 - 10:09:39 GMT

Worked perfectly with the new code you posted the link to, thank you!!!!!

Re: using Target=_blank links with buildlistmenu


Poster: Thoth
Dated: Monday February 18 2008 - 21:26:19 GMT

How can this be implemented for use with the Mac style drop-down menu?

Re: using Target=_blank links with buildlistmenu


Poster: Thoth
Dated: Monday February 18 2008 - 22:19:40 GMT

Nevermind my previous post... I got it to work by adjusting the bit of code that I'm most familiar with using. :D

Re: using Target=_blank links with buildlistmenu


Poster: Ruth
Dated: Tuesday February 19 2008 - 18:50:17 GMT

Hi,

Could you post what you did so others might know how to do it?

Ruth

Re: using Target=_blank links with buildlistmenu


Poster: Thoth
Dated: Wednesday February 20 2008 - 2:02:31 GMT

I just made sure I used this version of code:

target=_blank

I merely added that immediately after the link and before the last quotes with no spaces in between. If it's not precisely like that, it won't work in all browsers.

aI("separatorsize=1;text=YOUR LINK DISPLAY TEXT;url=HTTP://WWW.YOUR OFFSITE LINK GOES HERE.COM;target=_blank");