hi! has this issue been solved already?

got something like this:

Dependent to an existing member?

<label class="custom-checkbox checked" data-bind="css: { checked: 
isDependent() }, click: toggleAsDependent">
<span>Dependent to an existing member?</span>
<input type="checkbox"/>
<i/>
</label>

I have a method in ruby for checking the checkbox. Now on another method, I 
want to access/see whether the checkbox is checked, if yes, I will do 
something.

in irb, the checkbox.exists? returns true so I know that the element is in 
the page. but thing is even if I check or uncheck the checkbox, the 
checkbox.checked? always returns false.

another info is, the label class is "custom-checkbox" when unchecked, then 
becomes "custom-checkbox checked" when checked



On Thursday, November 7, 2013 at 6:04:42 AM UTC+8, Mihir Dhandhusaria wrote:
>
> This is my html 
>
> <label for="termsAgree" class="checkbox">
>     <span class="sprite"></span>
>     <input type="checkbox" name="termsAgree" data-original-title="" 
> title=""> 
>     <span class="message">I agree to the <a href="/termsandconditions" 
> target="_blank" class="inline" title="Terms and Conditions">Terms and 
> Conditions</a></span>
> </label>
>
> I tired following things and none of them seems to be working.
>
> Option 1:
>   $browser.label(:class => 'checkbox').parent.checkbox(:name => 
> 'termsAgree').set 
>
> Option 2:
>  $browser.checkbox(:name => 'termsAgree').focus
>
>
> Any help is appreciated. 
>
> Thanks 
>
>
>
>

-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

[email protected]
http://groups.google.com/group/watir-general
[email protected]

--- 
You received this message because you are subscribed to the Google Groups 
"Watir General" 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/d/optout.

Reply via email to