My javascript pop-up script no longer works with Milonic.

Having problems with DHTML Menu? There is usually somebody here who knows the answer.
Post Reply
chill
Beginner
Beginner
Posts: 4
Joined: Fri Sep 26, 2003 8:47 pm

My javascript pop-up script no longer works with Milonic.

Post by chill »

My pop-up script no longer works with Milonic.

URL: http://65.48.148.5/hivaids/site/search.cfm

I have a simple link on this page called "HELP" beside the GEOGRAPHICAL AREA section of the form. The link calls a javascript pop-up function.

Here is the javascript for the popup:

<script language="JavaScript" type="text/javascript">
function popup(url, name, width, height)
{
settings=
"toolbar=no,location=no,directories=no,"+
"status=no,menubar=no,scrollbars=yes,"+
"resizable=yes,width="+width+",height="+height;

MyNewWindow=window.open(url,name,settings);
}
</script>

here is the link:

<a href="javascript:popup('help_popup.cfm', 'Win1', 500, 400);">HELP</a>

This used to work great!

However, since putting the vertical menu on this page, the script doesn't work. If you use Netscape and do "javascript:" in the URL, it gives the following error message:

JavaScript Error:
http://65.48.148.5/hivaids/site/mmenuns4.js, line 16:

_m[_mnu] has no properties.


I don't get it.

Please help asap.

Thanks.
User avatar
DMLCo
Advanced
Advanced
Posts: 21
Joined: Fri Sep 19, 2003 4:29 pm
Location: Houston, TX
Contact:

Post by DMLCo »

Milonic also uses popup() as the name of one of it's functions.

Rename your function to popme or newwin or whatever, and it should work.

Yours,

Daniel
DMLCo
Solving the Challenges Where People & Technology Meet
Featuring DMLContent Content Management System
http://www.dmlco.com/
chill
Beginner
Beginner
Posts: 4
Joined: Fri Sep 26, 2003 8:47 pm

Post by chill »

Thank you ... that fixed it ... too bad this wasn't in any documentation.

Later,

Cheryl
User avatar
Ruth
 Team
 Team
Posts: 8763
Joined: Thu May 15, 2003 5:02 am
Location: Yucaipa, CA
Contact:

Post by Ruth »

Is it really the use of that in the menu that's doing it? It would seem if that's the case that the thousands of websites out there who use that term would have conflicts. Just an idea, if that's the case, wouldn't it be better to change the name of the function in the menu rather than have it have that problem with however many hundreds of sites that may already have that function on them?

Ruth
User avatar
kevin3442
Milonic God
Milonic God
Posts: 2460
Joined: Sat Sep 07, 2002 12:09 am
Location: Lincoln, NE
Contact:

Post by kevin3442 »

The same popup() function was in v3 (where I had most of my experience a while back). And although the same issue came up now and then, it was pretty rare. You have a good point just the same. Perhaps they left it named popup() to keep v5 backwardly compatible with developers who used the Milonic popup() function for their own purposes? Just a hunch.

Kevin
Post Reply