Forms Problem

JavaScript and client side scripting.

Moderator: General Moderators

Post Reply
User avatar
John Cartwright
Site Admin
Posts: 11470
Joined: Tue Dec 23, 2003 2:10 am
Location: Toronto
Contact:

Forms Problem

Post by John Cartwright »

Lets say I have a list

List1
-Item1
-Item2
-Item3
-Item4

List2
-Item1
-Item2
-Item3
-Item4

And depending what one is chosen, different things will be in the next list (list2)... like the page will reload.. .I've seen this done when there are like countries and when like Canadian is shown it changes to just show Provinces
Last edited by John Cartwright on Tue Feb 24, 2004 8:03 pm, edited 1 time in total.
User avatar
tim
DevNet Resident
Posts: 1165
Joined: Thu Feb 12, 2004 7:19 pm
Location: ohio

Post by tim »

javascript, heres a example:

http://js-x.com/javascript/?id=466
User avatar
John Cartwright
Site Admin
Posts: 11470
Joined: Tue Dec 23, 2003 2:10 am
Location: Toronto
Contact:

Post by John Cartwright »

This menu dynamically alters its presence to show the sub menus.

This code works for NS4, NS6 and IE. NS6 however does not have images that change.

To add in hyper links, find code like this:

t.addItem("Dynamic HTML");

and change it to:

t.addItem("<a href='page.html'>Dynamic HTML</a>");







WT...EF :) Can someone help me on this?
User avatar
no_memories
Forum Contributor
Posts: 145
Joined: Sun Feb 01, 2004 7:12 pm
Location: New York City

Post by no_memories »

ALA http://www.alistapart.com/ has a scripted version of that type of menu, or you can get into CSS 2 child selectors. Which I.E. is broken when it comes to CSS 2.

Here is an example of child selectors: http://www.thexvector.us/css2childss.php : works in Mozilla or Opera, not sure about KDE or Safari. I'm guessing KDE and Safari can handle it too.
Post Reply