943,770 Members | Top Members by Rank

Ad:
Nov 3rd, 2008
0

Plz Help

Expand Post »
i need to add an option from list1 to list2 when the user clicks on ADD to List button
but sth is wrong with my code it's not working

function AddItem()
{


var opt = document.getElementById("List1").selectedIndex;


document.getElementById("List2").options.add(opt);



}
can anyone tell me whats wrong ??!!!!!!
Similar Threads
Reputation Points: 10
Solved Threads: 0
Light Poster
yasmena is offline Offline
45 posts
since May 2008

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in JavaScript / DHTML / AJAX Forum Timeline: use an image metatag to generate a image title?
Next Thread in JavaScript / DHTML / AJAX Forum Timeline: Ajax with :





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC