$('input:radio').click(function() { alert(this.name); });

But... as radio buttons, wouldn't they all have the same name?

In any event, 'this' (or the jQuery $(this)) will give you a hook into the
element that triggered the click.

On Wed, Sep 2, 2009 at 12:44 PM, gilberto.ramoso...@gmail.com <
gilberto.ramoso...@gmail.com> wrote:

>
> Hello I have a bunch of radio button and I want a funtion tu run when
> any of the radio button is clicked so I used $('input:radio').click
> (function... what I want to do is to get the name attribute of the
> clicked radio, how can i do this?




-- 
I have failed as much as I have succeeded. But I love my life. I love my
wife. And I wish you my kind of success.

Reply via email to