DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 3 of 3

Thread: Combo box HTML

  1. #1
    Join Date
    Aug 2004
    Posts
    43,023

    Combo box HTML

    [Originally posted by Peter]

    I have a combo box within a div tag and the client script to handle the on click event. This script works fine. Later in the page I replace the inner html of the div tag with a new select and option list with the same name and id. The problem is then that the client script for the on click event no longer works. Any ideas why?

  2. #2
    Join Date
    Aug 2004
    Posts
    43,023

    Re:Combo box HTML

    [Originally posted by David Nishimoto]

    A select box does not have an onclick event. use the onchange event.

    <select id="abc" onchange="myFunction();">
    <option>1
    </select>

    David Nishimoto

  3. #3
    Join Date
    Aug 2004
    Posts
    43,023

    Re:Combo box HTML

    [Originally posted by David Nishimoto]

    A select box does not have an onclick event. use the onchange event.

    <select id="abc" onchange="myFunction();">
    <option>1
    </select>

    David Nishimoto

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center
 
 
FAQ
Latest Articles
Java
.NET
XML
Database
Enterprise
Questions? Contact us.
C++
Web Development
Wireless
Latest Tips
Open Source


   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center