WebFX WebBoard
Message Thread:
View All Messages
Back to WebFX
 select multiple, noname, November 10, 2003
     Re:select multiple, Kiwi, November 16, 2003

Subject: Re:select multiple From: Kiwi Date: November 16, 2003

<script language="javascript">
<!--
function isMultipleSelected(select){
 var count = 0;
 var i =0;
 var length = select.options.length
 for(i;i<length;i++){
  if(select.options[i].selected)
   count++
  if(count > 1) return true
 }
 return false
}

//-->
</script>

<select  multiple onchange="alert( isMultipleSelected( this ) )">
<option>1</option>
<option>1</option>
<option>1</option>
<option>1</option>
</select>

From: noname
Sent: November 11, 2003
Subject: Re:select multiple

I have a <select multiple ...

how can I test (on onchange event) if multiple options are selected?

(without using other hiden inputs or js variables)

 

Thank you!





Reply
Name: 
Email: 
Subject: 

Enter your reply to this message below. HTML tags are not supported but words that start with http://, ftp:// or mailto: are converted to links.


View All Messages
Back to WebFX