PDA

View Full Version : An imagemaps, javascript and database question!


brianellisrules
Oct 29, 2003, 06:05 PM
Hey, I have an image map setup with several "onmouseover" javascript commands that activate pop up menus. The thing is, these menus will be added to quite often and already my javascript header is getting massive. Is there a way to setup a database file so that on a mouseover on a certain area, it'll bring up values from a database to populate the menu(s) with?

Here's what I have: www.brianellisrules.com/stickers/

Each of the towns listed for a particular state are all listed in the header portion of the page. It's getting pretty bulky. What I'd like to do is have a database file with all the info that the script will access to bring up the values.

Is there a downside to using a database (if possible) for this? If so, is there a better way?

Thanks!

Rower_CPU
Oct 29, 2003, 07:34 PM
A DB could definitely help out, but...

Personally, I think you should rethink the image maps, since they are bad for accessibility. The long rollovers are tricky, too, since they can flow off the bottom of the screen.

I'd recommend doing something simpler like this: http://www.apple.com/retail/

Not as fun, but more functional.

brianellisrules
Oct 29, 2003, 08:12 PM
Hmmm, ok, pretend I have a mac now and answer the question... :D




I hear ya though. The alternate method didn't look very fun at all unfortunately. This is definitely a novelty thing anyway though.

Is there a way to make the long listing (i.e. New Jersey) break down into 2 or more columns?

Rower_CPU
Oct 29, 2003, 08:27 PM
To be honest, I don't do a whole lot with javascript, so I can't give you something off the top of my head.

You can probably do it manually (i.e. make a modified js that loads 2 columns for the more prolific states.

jelloshotsrule
Oct 29, 2003, 09:20 PM
hey b-dawg. mike may be able to help....