PDA

View Full Version : How do i....



Forge
04-12-2007, 04:50 PM
It may sound stupid but how do i make a dropdown box where the options work as hyperlinks?

Pazza
04-12-2007, 05:18 PM
Only one I could find ;) (http://www.dynamicdrive.com/dynamicindex1/combodescribe.htm)

=)

If you dont like it, search around - you'll find one!

Forge
04-12-2007, 05:23 PM
Ive sorted it now thanks though! +rep ;)

Mr Macro
04-12-2007, 08:36 PM
I wont post the code, because the best way to learn is to think. But basically, in PHP you could do a if to see if a form has been posted. Then, if it has it executes a JavaScript thingy to change the page, if the if says the form hasn't been posted echo the form. There is probably a simple JavaScript way, but i don't like JavaScript.

Chippiewill
04-12-2007, 08:43 PM
Yeh its javascript, on dreamweaver its called spry watever that means

Mr Macro
04-12-2007, 08:47 PM
Yeh its javascript, on dreamweaver its called spry watever that means

I thought it would be JavaScript, i wouldn't know about dream weaver because i have never used a program like dream weaver.

Invent
04-12-2007, 08:59 PM
<select name="name">
<option onClick="javascript:window.location = 'http://google.com';">Google</option>
</select>


Simple.

Mr Macro
04-12-2007, 09:14 PM
<select name="name">
<option onClick="javascript:window.location = 'http://google.com';">Google</option>
</select>
Simple.

I thourght there would be a JavaScript way of doing it.Nice one invent.

Want to hide these adverts? Register an account for free!