[jQuery] Re: alerting the value of radio button onfocus

2007-05-23 Thread Roger Roelofs
Stef, On May 22, 2007, at 10:40 AM, stef wrote: when a radio button is clicked, show its value. i have the code below, which i dont think is the best way to go about it. it always alerts undefined. my reasoning is: when the document has loaded, and an input element in the div with id 'test'

[jQuery] Re: alerting the value of radio button onfocus

2007-05-22 Thread Jörn Zaefferer
stef wrote: that's what im trying to do - when a radio button is clicked, show its value. How about this: $(input:radio).focus( function() { alert(this.value); }); -- Jörn Zaefferer http://bassistance.de

[jQuery] Re: alerting the value of radio button onfocus

2007-05-22 Thread Jean Nascimento
or u can use .val() On 5/22/07, Jörn Zaefferer [EMAIL PROTECTED] wrote: stef wrote: that's what im trying to do - when a radio button is clicked, show its value. How about this: $(input:radio).focus( function() { alert(this.value); }); -- Jörn Zaefferer http://bassistance.de