[Javascript] in response to "add a new entry in a drop down menu"

Smitha Ramaswamy smitha.ramaswamy at wipro.com
Tue Jun 24 23:59:56 CDT 2003


FiestaHi,

I have attached a very simple html with JS code that will enable you to add
a new element to the combo box.
I hope this is of some help to you.Do get back to me in case of any queries.

<HTML>
<HEAD>
<TITLE> New Document </TITLE>
<META NAME="Generator" CONTENT="EditPlus 1.2">
<META NAME="Author" CONTENT="">
<META NAME="Keywords" CONTENT="">
<META NAME="Description" CONTENT="">
</HEAD>

<BODY BGCOLOR="#FFFFFF">
<FORM>
<SELECT NAME="test">
<option value="1">one</option>
<option value="2">two</option>
</SELECT>

<SCRIPT LANGUAGE="JavaScript">
     document.forms[0].test.options[document.forms[0].test.options.length] =
new Option('three','3')
</SCRIPT>

</FORM>
</BODY>
</HTML>


Regards,
Smitha


**************************Disclaimer************************************

Information contained in this E-MAIL being proprietary to Wipro Limited is 
'privileged' and 'confidential' and intended for use only by the individual
 or entity to which it is addressed. You are notified that any use, copying 
or dissemination of the information contained in the E-MAIL in any manner 
whatsoever is strictly prohibited.

***************************************************************************
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.evolt.org/pipermail/javascript/attachments/20030625/4b1c4e04/attachment.htm>


More information about the Javascript mailing list