Set the value of a dropdown using Javascript?

  •  12-21-2007, 7:57 AM

    Set the value of a dropdown using Javascript?

    How can I set the value of a dropdown using Javascript? e.g. Have Courier selected in the Default Font dropdown. This must be done using Javascript as the value I want to select depends on choices the user has made client side.
     
    I am able  to grab the element but am not able to find a way to set the selected index ... does anybody have any ideas?
     
    lp = document.getElementById('CE_ctl00_ctl01_bcr_PostForm___PostBody___Editor_IDfontname');
    if(lp)

        {
        ????????
        }


View Complete Thread