RwL schrieb:
I'd like to extend this simple function but don't know what to do
next:
$('select').change(function(){
$('.formTip').show();
});
What I really want this to do, is:
On the change event, check to see if any value of any <select> element
on the page matches the value of any other <select> on the page -- if
so, show .formTip. If they've made a change so that two values no
longer match, hide it again.
I'm still wrapping my brain around all the ways jQuery can select and
extend the selection; can't figure this one out.
Thanks,
Rob
Hi Rob,
maybe something like this:
$('select').change(function(){
if ( $('[EMAIL PROTECTED]' + this.value + ']').not(this).length )
{
$('.formTip').show();
}
else
{
$('.formTip').hide();
}
});
Cheers,
/rw