The class 'active' is add to the element, soo u should use the function
hasClass to verirfy

if ($('#btntest').hasClass('active')) {


}




Atenciosamente,

Vinícius Moraes


2013/2/8 TimBa <[email protected]>

> Hi List,
> i am new in using bootstrap. So i have one important (for me) question. I
> am using toogle button
>
> <button type="button" id="btntest" class="btn btn-inverse"
> data-toggle="button">Test</button>
>
> Now, i only want to check the status of the button via javascript function.
>
> function statustest()
> { if ($('#btntest').activated())
> {alert ("on");}
> else
> {alert("off")}
> }
>
> but i do not find any function like "activated".
> So i hope some oy sou can help me. thanks a lot
> TimBa
>
>  --
> You received this message because you are subscribed to the Google Groups
> "twitter-bootstrap" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"twitter-bootstrap" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to