Alternatives to javascript menus.

J

John

I normally write web pages in the simplest way I can get away with
(using XHTML, basic CSS and PHP). A recent customer wants a site with
nested menus that activate on rollover (you've seen it a million times
in javascript). I get quite annoyed trying to get javascript menus like
this to work across a range of browsers, and it normally takes a lot of
hacky scripting to get it to work. What alternatives to the javascript
would you suggest?

John
 
B

brucie

In alt.html John said:
A recent customer wants a site with nested menus that activate on
rollover (you've seen it a million times in javascript).

do you mean the dropdown menu type of thingys with nested sub menus?
they're not a user friendly way to navigate a site.

think back to when you last got a new bit of giggly software and had to
hunt through the menus looking for what you wanted before you remembered
where everything was.

its the same thing except worse on a website. most people spend their
time on other websites, not learning how to navigate yours. many menus
don't even indicate where you've been before. remember its easy for you,
you did it, you know where everything is. the visitor doesn't and they
have to hunt to find it.
What alternatives to the javascript would you suggest?

http://www.alistapart.com/articles/horizdropdowns/
 
J

John

brucie said:
In alt.html John said:




do you mean the dropdown menu type of thingys with nested sub menus?
they're not a user friendly way to navigate a site.

think back to when you last got a new bit of giggly software and had to
hunt through the menus looking for what you wanted before you remembered
where everything was.

its the same thing except worse on a website. most people spend their
time on other websites, not learning how to navigate yours. many menus
don't even indicate where you've been before. remember its easy for you,
you did it, you know where everything is. the visitor doesn't and they
have to hunt to find it.

You're preaching to the converted brucie.

Looks interesting. I'll see if I can get a horizontal rather than
vertical menu bar.

Thanks.
 
S

SpaceGirl

Sybren said:
John enlightened us with:
A recent customer wants a site with nested menus that activate on
rollover [...] What alternatives to the javascript would you
suggest?


These folks use nothing but CSS for their menus:

http://www.meyerweb.com/eric/css/edge/menus/demo.html
http://www.howtocreate.co.uk/tutorials/testMenu.html

Sybren

yes, using the :hover psuedo-class. IE does not support this class,
which means 95% of visitors will never see your menu. Useless in other
words. IE only supports :hover on <a> tags. These guys use it on <ul>
tags to get the desired effect.

--


x theSpaceGirl (miranda)

# lead designer @ http://www.dhnewmedia.com #
# remove NO SPAM to email, or use form on website #
 
S

Sybren Stuvel

SpaceGirl enlightened us with:
yes, using the :hover psuedo-class. IE does not support this class,
which means 95% of visitors will never see your menu.

Which isn't a problem. The main items should link to a page where the
sub-items can be selected.
Useless in other words.

Far from it.
IE only supports :hover on <a> tags. These guys use it on <ul> tags
to get the desired effect.

I know. If you take a good look at the page, though, you'll see that
they also give JavaScript code for MSIE to accomplish the same thing.

Sybren
 
C

C A Upsdell

SpaceGirl said:
Sybren said:
John enlightened us with:
A recent customer wants a site with nested menus that activate on
rollover [...] What alternatives to the javascript would you
suggest?


These folks use nothing but CSS for their menus:

http://www.meyerweb.com/eric/css/edge/menus/demo.html
http://www.howtocreate.co.uk/tutorials/testMenu.html

Sybren

yes, using the :hover psuedo-class. IE does not support this class, which
means 95% of visitors will never see your menu. Useless in other words. IE
only supports :hover on <a> tags. These guys use it on <ul> tags to get
the desired effect.

There is a workaround for IE that uses a little JavaScript. And for those
who have disabled JavaScript, it is not hard to make the site usable for
them as well, though without the roll-down / pull-down / fly-out menus.
 
M

Matthew Superstar Swass

yes, using the :hover psuedo-class. IE does not support this class,
Which isn't a problem. The main items should link to a page where the
sub-items can be selected.

So in other words, drop JS because 5% of the internet has it disabled for
something that 95% overall can't see.

You may as well keep JS and link the main items to other pages where the
sub-items can be selected. This way 5% is put through that hassle instead of
95%.
 
N

Neal

So in other words, drop JS because 5% of the internet has it disabled for
something that 95% overall can't see.

No, don't rely on JS so no one is inconvenienced.
You may as well keep JS and link the main items to other pages where the
sub-items can be selected. This way 5% is put through that hassle
instead of
95%.

As long as no-JS users can still use the site, do all the JS you want.
Once something needed on the site is reliant on JS, you're in trouble.
 
K

Kris

Which isn't a problem. The main items should link to a page where the
sub-items can be selected.

So in other words, drop JS because 5% of the internet has it disabled for
something that 95% overall can't see.[/QUOTE]

Of course not. Make your site accessible to 100% and enhance it's
functions for 95%. Doesn't that sound like a better deal to you?
You may as well keep JS and link the main items to other pages where the
sub-items can be selected. This way 5% is put through that hassle instead of
95%.

Which is what he says. If you'd also quote the name of the person you
are replying to next time, then we will know who it was who said it.
 
K

King of Red Lions

John said:
I normally write web pages in the simplest way I can get away with
(using XHTML, basic CSS and PHP). A recent customer wants a site with
nested menus that activate on rollover (you've seen it a million times
in javascript). I get quite annoyed trying to get javascript menus like
this to work across a range of browsers, and it normally takes a lot of
hacky scripting to get it to work. What alternatives to the javascript
would you suggest?

John

Don't know if it helps but here is just a little something I knocked up
in a few minutes and uses just css, unfortunately it uses a number of
pages, this could be easily improved with a bit of spiffy php.

http://www.freewebs.com/softek
 
D

Duende

While sitting in a puddle King of Red Lions scribbled in the mud:
Don't know if it helps but here is just a little something I knocked up

Please don't do that to brucie
 
S

SpaceGirl

Sybren said:
SpaceGirl enlightened us with:



Which isn't a problem. The main items should link to a page where the
sub-items can be selected.




Far from it.




I know. If you take a good look at the page, though, you'll see that
they also give JavaScript code for MSIE to accomplish the same thing.

Sybren

You're missing the point. This was about fly out menus. As demonstrated
it cannot be done without scripting, or a CSS class that is only
supported by 5% of the market. Yes there are plenty of other ways of
doing menus that dont require either. But the OP specifically asked for
alternatives to a JS menu. There aren't any, other than regular static
always-visible menus.

--


x theSpaceGirl (miranda)

# lead designer @ http://www.dhnewmedia.com #
# remove NO SPAM to email, or use form on website #
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,774
Messages
2,569,599
Members
45,175
Latest member
Vinay Kumar_ Nevatia
Top