[jQuery] Re: Multiple-select-box: set multiple to false

2007-07-05 Thread Thomas Jaggi
Are you sure you're not getting an error somewhere in the execution path? I've never tried toggling a select element between a multiple select and a single select. It seems it just doesn't work in Safari if the .hide()-stuff is before the multiple = false. Well, whatever. Quite frankly, this

[jQuery] Re: Multiple-select-box: set multiple to false

2007-07-05 Thread Mike Alsup
Quite frankly, this just feels "wrong". Is there a reason you're doing this? :-) I was thinking the same thing, Dan. In fact, I'd be surprised if this works at all. "multiple" may be an attribute but I think the element "type" ("select-multiple") is the key to the actual gui component styl

[jQuery] Re: Multiple-select-box: set multiple to false

2007-07-05 Thread Dan G. Switzer, II
>I just wanted to reply that wouldn't work either but there was another >problem: >When I'm hiding some elements of the form BEFORE I set multiple to >false, it doesn't work: > $("#field2").hide(); > $("#field3").hide(); > $("#field6").hide(); > $("[EMAIL PROTECTED]")[0].multiple = false; > >L

[jQuery] Re: Multiple-select-box: set multiple to false

2007-07-05 Thread Thomas Jaggi
Try: $("[EMAIL PROTECTED]")[0].multiple = false; You need to actually reference the actual DOM object, not the jQuery array of objects that gets returned. Thanks a lot for your help! I just wanted to reply that wouldn't work either but there was another problem: When I'm hiding some elements

[jQuery] Re: Multiple-select-box: set multiple to false

2007-07-05 Thread Dan G. Switzer, II
>I'm trying to set a multiple-select-box to multiple=false, but neither > $("[EMAIL PROTECTED]").multiple = false; Try: $("[EMAIL PROTECTED]")[0].multiple = false; You need to actually reference the actual DOM object, not the jQuery array of objects that gets returned. -Dan