Click here to Skip to main content
16,011,849 members
Home / Discussions / Web Development
   

Web Development

 
GeneralRe: select boxs and javascript Pin
Richard Deeming4-Aug-03 4:03
mveRichard Deeming4-Aug-03 4:03 
GeneralRe: select boxs and javascript Pin
skizzly4-Aug-03 7:23
skizzly4-Aug-03 7:23 
GeneralRe: select boxs and javascript Pin
Richard Deeming4-Aug-03 9:02
mveRichard Deeming4-Aug-03 9:02 
GeneralRe: select boxs and javascript Pin
skizzly4-Aug-03 9:09
skizzly4-Aug-03 9:09 
GeneralRe: select boxs and javascript Pin
skizzly6-Aug-03 1:50
skizzly6-Aug-03 1:50 
GeneralRe: select boxs and javascript Pin
Richard Deeming6-Aug-03 2:29
mveRichard Deeming6-Aug-03 2:29 
GeneralRe: select boxs and javascript Pin
skizzly6-Aug-03 3:46
skizzly6-Aug-03 3:46 
GeneralRe: select boxs and javascript Pin
Richard Deeming6-Aug-03 4:01
mveRichard Deeming6-Aug-03 4:01 
The first issue is the case of the value - the function is looking for "other", in lower case. The second issue is the fact that your list allows multiple selection - the selectedIndex will only return the first selected item.

Try changing the function to:
function other(cbx)
{
    if (!cbx || "undefined" == typeof(cbx.options)) return false; 
    
    var selOther = false;
    for(var i = 0; i < cbx.options.length; i++)
    {
        var opt = cbx.options[i];
        if (opt.selected && "other" == opt.value.toLowerCase())
        {
            selOther = true;
            break;
        }
    }
    
    if (selOther)
    {
        window.open("form.htm", "", "top=20,width=200,height=200");
        return true;    
    }
    else
    {
        return false;    
    }
}



"These people looked deep within my soul and assigned me a number based on the order in which I joined." - Homer
GeneralRe: select boxs and javascript Pin
skizzly12-Aug-03 2:00
skizzly12-Aug-03 2:00 
GeneralI cant view Unicode in IE. Help Pin
lnong1-Aug-03 4:23
lnong1-Aug-03 4:23 
Generalcursor change Pin
Brakanjan1-Aug-03 2:33
Brakanjan1-Aug-03 2:33 
GeneralRe: cursor change Pin
basementman1-Aug-03 8:50
basementman1-Aug-03 8:50 
GeneralJS: Sort table problem Pin
DrJ21-Aug-03 1:29
DrJ21-Aug-03 1:29 
QuestionPERL: How come I cant print out Unicode characters? Pin
lnong31-Jul-03 13:00
lnong31-Jul-03 13:00 
GeneralMSDE PROBLEM Pin
eggie531-Jul-03 11:03
eggie531-Jul-03 11:03 
GeneralRe: MSDE PROBLEM Pin
Paul Ingles31-Jul-03 23:18
Paul Ingles31-Jul-03 23:18 
GeneralRe: MSDE PROBLEM Pin
eggie51-Aug-03 15:17
eggie51-Aug-03 15:17 
QuestionCan I download IIS5.0? Pin
Anonymous31-Jul-03 10:35
Anonymous31-Jul-03 10:35 
AnswerRe: Can I download IIS5.0? Pin
Roger Wright31-Jul-03 11:07
professionalRoger Wright31-Jul-03 11:07 
AnswerRe: Can I download IIS5.0? Pin
Vasudevan Deepak Kumar4-Aug-03 23:15
Vasudevan Deepak Kumar4-Aug-03 23:15 
GeneralRedirecting main parent window with JavaScript Pin
Paul Ingles31-Jul-03 6:23
Paul Ingles31-Jul-03 6:23 
Generalopening new page in same window Pin
haritadala30-Jul-03 14:21
haritadala30-Jul-03 14:21 
GeneralRe: opening new page in same window Pin
Not Active30-Jul-03 14:35
mentorNot Active30-Jul-03 14:35 
GeneralRe: opening new page in same window Pin
Bjoern Graf30-Jul-03 18:56
Bjoern Graf30-Jul-03 18:56 
QuestionWhat other server besides IIS can run .NET Web applications and services? Pin
ElizabethC30-Jul-03 11:52
ElizabethC30-Jul-03 11:52 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.