It sounds to me like you want the .change event to fire if someone
selects an option that's already selected. If that's the case, try
this:

$(function(){
   $('.agents')
       .focus(function(){
           $('option:selected', this).attr('selected', '');
       })
       .change(function(){
            // Your function here?
       });
});

Otherwise, I might not quite understand the problem. Can you give an
HTML sample?

On Feb 3, 9:39 am, "Rick Faircloth" <r...@whitestonemedia.com> wrote:
> Hi, all...
>
> Here's the code:
>
> $(document).ready(function() {          
>
>    $('.agents').change(function() {
>
>       $('option:selected', this).each(function() {
>
> Here's the problem:
>
> I would like for the function triggered in the code
> above by ".change" to work if the same value is chosen
> in the select element ".agents".
>
> Right now, the function following .change is only triggered
> if another value is selected.  I tried .select, but that didn't work.
> I tried .click, too, but that wasn't satisfactory.
>
> Anyone have another option?
>
> Thanks,
>
> Rick

Reply via email to