9 messages in com.canoo.lists.webtest[Webtest] setCheckbox doesn't work fo...| From | Sent On | Attachments |
|---|---|---|
| Andrew Sickorsky | 17 Sep 2007 05:40 | |
| Marc Guillemot | 19 Sep 2007 06:01 | |
| Andrew Sickorsky | 19 Sep 2007 07:18 | |
| Andrew Sickorsky | 20 Sep 2007 00:38 | |
| Marc Guillemot | 20 Sep 2007 00:38 | |
| Marc Guillemot | 20 Sep 2007 01:11 | |
| Andrew Sickorsky | 20 Sep 2007 05:47 | |
| Marc Guillemot | 20 Sep 2007 06:15 | |
| Marc Guillemot | 20 Sep 2007 06:42 |
| Subject: | [Webtest] setCheckbox doesn't work for some kind of checkboxes?![]() |
|---|---|
| From: | Andrew Sickorsky (andr...@texunatech.com) |
| Date: | 09/17/2007 05:40:42 AM |
| List: | com.canoo.lists.webtest |
Hello again!
It's strange, but setCheckbox sometimes doesn't work for our application (see checkbox with ID user[role_ids][]) neither <setCheckbox name="user[role_ids][]" value="1" /> nor <setCheckbox xpath="//*[@id='[user[role_ids][]'" value="1" /> nor <clickElement xpath="//*[@id='user[role_ids][]'and @value='1']" />
Confusing for me, but for another checkbox (ID = user_disabled) all works. Seems that problem is in HTML code. But I can't see it.
Regards Andrew.
Html code:
<form action="/admin/user/update/24" method="post"> <div class="app_form"> <fieldset class="editUser"> <legend>Enter User Details</legend>
...
<label for="user_roles">Roles:</label> <table id="user_roles">
<tr> <td> <input class="check" id="user[role_ids][]" name="user[role_ids][]" type="checkbox" value="1" /> </td> <td> admin </td> </tr>
<tr> <td> <input class="check" id="user[role_ids][]" name="user[role_ids][]" type="checkbox" value="2" /> </td> <td> expense_claim_supervisor </td> </tr>
<tr> <td> <input class="check" id="user[role_ids][]" name="user[role_ids][]" type="checkbox" value="3" /> </td> <td> finance </td> </tr>
</table>
<label for="user_disabled">Status:</label> <table id="user_status"> <tr> <td> <input checked="checked" class="check" id="user_disabled" name="user[disabled]" type="checkbox" value="1" /><input name="user[disabled]" type="hidden" value="0" /> </td> <td> Disabled </td> </tr> </table> ....
</fieldset> </div> <input class="button formBottomButton" name="commit" type="submit" value="Save" /> </form>




