Hey,

I have basically zero knowledge of javascript, ajax, etc so any help is much appreciated.

Basically I'm making a site that has an html option drop down list. I was wondering if there was a script out there / if one of you could write the script for me that when a certain option was selected a text input field would replace the option field...?

I have a few different options and when the user selects "Other" I want the option box to go away and...

<input type="text" name="vendor" value="Vendor Name" onfocus="this.value=''">

to replace that drop down list...

Thanks for any help :).

Bkim,

If I understand correctly then help is readily available in the form of a "combobox".

This is a pulldown menu into which the user can also type his own entry - a hybrid form element.

HTML doesn't provide native comboboxes but you can employ one of several javascript libraries that will build one for you, eg, jQuery/jQuery UI, Mootools, javascriptKit

Google (or Alta Vista/Dogpile/Yahoo Search etc.) to find out more.

Airshow

Thank you! I didn't know what the name to google it was lol. Thanks for your help.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.