a name targeting probem

Having problems with DHTML Menu? There is usually somebody here who knows the answer.
Post Reply
Wavmixer
Beginner
Beginner
Posts: 8
Joined: Wed Dec 10, 2003 2:14 am

a name targeting probem

Post by Wavmixer »

The site is http://www.wavmixer.com

When you go to "Services", "Clients" and then select a client, I would like to go to a specific location on that page. I am using the <a name> tag in the web page.
Here is a sample of my menu_data.js

Code: Select all

with(milonic=new menuname("Clients")){
style=menuStyle;
aI("text=Keyboard Concepts;showmenu=KeyboardConcepts;text=Keyboard Concepts;url=clients.html#KeyboardConcepts;");
aI("text=MCD Advertising;showmenu=MCD;url=clients.html#MCD;");
aI("text=Sold By Gold;showmenu=SoldByGold;url=clients.html#SoldByGold;");
aI("text=LightWav;showmenu=LightWav;url=clients.html#LightWav;");
aI("text=Bon Appetite Bakery;showmenu=BonAppetite;url=clients.html#BonAppetite;");
aI("text=Hacienda Imports;showmenu=HaciendaImports;url=clients.html#HaciendaImports;");
aI("text=Bulbs That Last 4 Ever;showmenu=BulbsThatLast4Ever;url=clients.html#BulbsThatLast4Ever;");
aI("text=Dobi Nicole;showmenu=DobiNicole;url=clients.html#DobiNicole;");
aI("text=Advanced Hypnotherapy Institute;showmenu=AdvancedHypnoTherapy;url=clients.html#AdvancedHypnoTherapy;");
}

with(milonic=new menuname("KeyboardConcepts")){
style=menuStyle;
aI("image=menu_images/clients/KeyboardConcepts.jpg;url=clients.html#KeyboardConcepts;");
}

with(milonic=new menuname("MCD")){
style=menuStyle;
aI("image=menu_images/clients/MCD.jpg;url=clients.html#MCD;");
}

with(milonic=new menuname("SoldByGold")){
style=menuStyle;
aI("image=menu_images/clients/SoldByGold.jpg;url=clients.html#SoldByGold;");
}

with(milonic=new menuname("LightWav")){
style=menuStyle;
aI("image=menu_images/clients/LightWav.jpg;url=clients.html#LightWav;");
}

with(milonic=new menuname("BonAppetite")){
style=menuStyle;
aI("image=menu_images/clients/BonAppetit.jpg;url=clients.html#BonAppetite;");
}

with(milonic=new menuname("HaciendaImports")){
style=menuStyle;
aI("image=menu_images/clients/HaciendaImports.jpg;url=clients.html#HaciendaImports;");
}

with(milonic=new menuname("BulbsThatLast4Ever")){
style=menuStyle;
aI("image=menu_images/clients/BulbsThatLast4Ever.jpg;url=clients.html#BulbsThatLast4Ever;");
}

with(milonic=new menuname("DobiNicole")){
style=menuStyle;
aI("image=menu_images/clients/DobiNicole.jpg;url=clients.html#DobiNicole;");
}

with(milonic=new menuname("AdvancedHypnoTherapy")){
style=menuStyle;
aI("image=menu_images/clients/HypnoTherapy.jpg;url=clients.html#AdvancedHypnoTherapy;");
}
User avatar
John
 Team
 Team
Posts: 5967
Joined: Sun May 19, 2002 8:23 pm
Location: Phoenix, AZ
Contact:

Post by John »

It goes where it's supposed to on the client page, but does complain with a JS error. However, I'm not sure at this point that the error has anything to do with the menu (although you are quite a bit down-level).

Most of the <font> tags on your page are unclosed, as is <html>. Also, you have (right after <body>)...

Code: Select all

<div align="center">
  <center>
Both of these are unclosed as well. Remove the <div...> entirely and close the <center> in the appropriate place.

Let us know from there.
John
Wavmixer
Beginner
Beginner
Posts: 8
Joined: Wed Dec 10, 2003 2:14 am

Post by Wavmixer »

Thank you John,

I believe that I have closed all the tags that you mentioned. I am still getting the error:


A Runtime Error has occurred.
Do you wish to Debug?
Line:16
Error: Invalid argument.



When I open the debugger, the following line is highlighted: _gmi.style.background=_I[7]
This is found on mmenudom.js

I have not made any modifications to mmenudom.js Any ideas?
User avatar
John
 Team
 Team
Posts: 5967
Joined: Sun May 19, 2002 8:23 pm
Location: Phoenix, AZ
Contact:

Post by John »

OK, this is getting strange.

I'm getting JS errors on your home page now, as follows...

1. Slowly move the mouse over the main menu items (not the subs), left to right (Home, Services, About, etc.) and stop on Contact. No errors yet.

2. Now move the mouse back from Contact to Lab. JS error!

Loaded your home page and data file on my server and corrected a few code errors on the index page (similar to what I mentioned before). However, I am using my local menu code files (but your downloaded data file - no changes).

See http://www.west.asu.edu/sa/testsite/wav.htm. Let me know when you're done so I can take it down.

No I can swing back and forth across your main menu items with no errors at all, so the thought is there might be something wrong with your set of code files. Try downloading them again and posting them to your server.

Let us know.
John
User avatar
kevin3442
Milonic God
Milonic God
Posts: 2460
Joined: Sat Sep 07, 2002 12:09 am
Location: Lincoln, NE
Contact:

Post by kevin3442 »

Wavmixer wrote:... I am still getting the error:... When I open the debugger, the following line is highlighted:
_gmi.style.background=_I[7]
This is found on mmenudom.js I have not made any modifications to mmenudom.js Any ideas?
Hope you guys don't mind me jumping in here... The error message is simply showing where the error is encountered while the code is being processed; it doesn't necessarily mean that the error is actually in that bit of code. In fact, that bit of code looks fine, so the conclusion I'd make is that there's a problem in the color code being used to set the menu item's background color. So, I had a look at your menu style...

The following line appears in the menuStyle definition in your menu_data.js file:

Code: Select all

pagebgcolor="#fffff";
I'm sure you'll see right away that you skipped an 'f'. I'm sure this will account for the js error. You could add the needed 'f' or, since you're using images for the main menu, completely remove pagecolor and pagebgcolor from the style, since they are not needed. While you're at it... you also have subimage=""; - I'd take that one out too. And at the bottom of menuStyle, you have keepalive, but there is no assigned value. It should be keepalive=1; or keepalive=true; if you aren't going to use it, then you should probably remove it.

I don't see the problem that started the thread... it looks to me like the menu items in the Clients menu are jumping to the appropriate anchors just fine.

Hope that helps,

Kevin
User avatar
John
 Team
 Team
Posts: 5967
Joined: Sun May 19, 2002 8:23 pm
Location: Phoenix, AZ
Contact:

Post by John »

Tank U! I missed that one.
John
User avatar
Ruth
 Team
 Team
Posts: 8763
Joined: Thu May 15, 2003 5:02 am
Location: Yucaipa, CA
Contact:

Post by Ruth »

That's a neat design. I'm using IE5.0 and I"m getting an error which is freezing my browser. It's at the contact mouseover for the email. Line: 17
Char: 5352 Error: Invalid argument. I think it might have to do with the % and stuff in that.

Ruth
Wavmixer
Beginner
Beginner
Posts: 8
Joined: Wed Dec 10, 2003 2:14 am

Post by Wavmixer »

Wow, thanks everyone. I gotta go do some cleaning up on my site. I'll be back. :D
Wavmixer
Beginner
Beginner
Posts: 8
Joined: Wed Dec 10, 2003 2:14 am

Post by Wavmixer »

I made all of the changes y'all suggested and everything is working fine now. Thanks again to everyone.
Post Reply