Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 6 of 6
  1. #1
    Regular Coder
    Join Date
    Jun 2004
    Posts
    112
    Thanks
    0
    Thanked 0 Times in 0 Posts

    document.form.element.click

    <td onmouseover="this.style.cursor='hand';" onclick="document.form.rca[1][0].checked = true; return false;">
    <input type="radio" name="rca[1]" value="strongly agree" class="layout">
    </td>

    Does anyone see a problem with that? On my test page I the problem seemed to be naming the input button an array.

  • #2
    Regular Coder
    Join Date
    Jun 2004
    Posts
    112
    Thanks
    0
    Thanked 0 Times in 0 Posts
    whoops, disregard this one

  • #3
    Supreme Master coder! glenngv's Avatar
    Join Date
    Jun 2002
    Location
    Philippines
    Posts
    11,033
    Thanks
    0
    Thanked 248 Times in 245 Posts
    onclick="document.form.elements['rca[1]'][0].checked = true; return false;"

    Is there any reason you're using a "bracketed" name? Are you using php?

    Learning the square bracket notation is very useful especially in this case.

  • #4
    Supreme Master coder! glenngv's Avatar
    Join Date
    Jun 2002
    Location
    Philippines
    Posts
    11,033
    Thanks
    0
    Thanked 248 Times in 245 Posts
    Quote Originally Posted by bnovc
    whoops, disregard this one
    I typed slow...But for the benefit of others, could you explain why?

  • #5
    Regular Coder
    Join Date
    Jun 2004
    Posts
    112
    Thanks
    0
    Thanked 0 Times in 0 Posts
    I used getElementById with the radios each unique

  • #6
    Regular Coder
    Join Date
    Jun 2004
    Posts
    112
    Thanks
    0
    Thanked 0 Times in 0 Posts
    edit: fixed new issue
    Last edited by bnovc; 06-23-2004 at 01:13 AM.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •