Simple way to create a sub menu

N

Nico Schuyt

My customer asked me to split up the menu of http://www.cartal.nl
I adviced him to use a non-js menu where the sub menu is hidden and shown
when a link is clicked (stylesheet switch with php; Like in
http://www.cartal.nl/menu_js/menu_php.php ; Click the main 2 link), but he
insists to have a sub menu on mouseover. Of course it should also work when
js is disabled.

A menu like the one on http://www.sidv.nl/index.htm is *way too complex* for
me so I started with the menu generator on
http://www.webdevtips.com/dropmenu/
Test file in http://www.cartal.nl/menu_js/ seems to work. The javascript
(view-source:http://www.cartal.nl/menu_js/cbddm.js ; 400 lines of code)
however still is beyond my knowledge of js (I hate complex coding :)

Can someone point me to a simpler solution?
Nico
 
A

Andy Dingley

Of course it should also work when
js is disabled.

When I've had to do this, I've coded something that's big and ugly,
but works with non-js.

Then there's a js window_onload event handler that hides most of it.
If they're running js, they don't see ti.
 
N

Nico Schuyt

Andy said:
Nico Schuyt wrote:
When I've had to do this, I've coded something that's big and ugly,
but works with non-js.
Then there's a js window_onload event handler that hides most of it.
If they're running js, they don't see ti.

Ehhhh, how does this solve my menu problem? :)
Nico
 
A

Andy Dingley

Ehhhh, how does this solve my menu problem? :)

You have two menus - one js, one non-js.

Initially the non-js one is visible (and maybe ugly), the js one is
invisible

On loading the page, _if_ js is running, then the non-js menu is
uninstalled and the js menu is installed / made visible.
 
N

Nico Schuyt

Andy said:
Nico Schuyt wrote:
You have two menus - one js, one non-js.
Initially the non-js one is visible (and maybe ugly), the js one is
invisible
On loading the page, _if_ js is running, then the non-js menu is
uninstalled and the js menu is installed / made visible.

Ah, I see :) Do you have an example of it?
Nico
 

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

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,055
Latest member
SlimSparkKetoACVReview

Latest Threads

Top