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:35
invalid argument error with sql as source
Poster: Buz
Dated: Wednesday August 17 2005 - 4:45:25 BST
I'm an asp developer so take it easy on me.
I'm having an issue with my sql driven menu. Everything works really well until I add a valid link in the url field of the mm_items table. The default oage isn't in the menu so when i load that there isn't an error but when I go to a valid link off my submenu i get the discreet error bottom left and the details are "invalid argument on line 21 (which is my include line for the asp that pulls menu items) char 6431 ".
From the docs and forum searches I can only assume that the matchpage function is erroring when the target loads. The odd thing is that it does it if I have a matchpage column or not. It's also changing the font color on the menu item of the loaded page. I've tried adding a matchpage column and making it null as well as entering the url and no change. Any help would be greatly appreciated.
Poster: kevin3442
Dated: Wednesday August 17 2005 - 5:11:44 BST
Hi Buz,
I notice that you have several of the menu's color properties set to "#" in your miniStyle definition (i.e., the style used by your menus). For example:
Code:
bordercolor="#";
Among these properties are pagecolor and pagebgcolor which, when the page matching routines come into play, cause the error, because these are indeed invalid color arguments.
I'm not sure why you're using "#". Maybe because you don't want to use those properties? I see similar things where you've used a null string (i.e., property=""). You'll want to avoid that also, although it isn't as bad. If you don't want to use a property, you can just omit it from your menu code. If you just want to temporarily disable a property, to try different things, you can comment that line out (as I'm sure you do in asp development). In javascript, you can comment out a single line by placing double forward slashes at the beginning of the line: // You can comment out a block of js code by placing /* at the front and */ at the end.
If you get rid of all the thisorthatcolor="#"; settings, or use valid color definitions, then the problem should go away.
Cheers,
Kevin
Poster: Buz
Dated: Wednesday August 17 2005 - 14:33:51 BST
That took care of it. I was adding the columns to the db to allow for maximum flexibility going forward. I built an asp backend for them to administer the style and I wanted them to have those columns available. I just went through and added a column for every feature that was in the default js.
Thanks again.