Search Results

Search found 1 results on 1 pages for 'user1985060'.

Page 1/1 | 1 

  • Changing class of h2 inside specific div

    - by user1985060
    I want to make it so that everytime you click on an 'h2' tag, the 'input' inside gets selected and the 'h2' tag changes background, but if another 'h2' tag is clicked, the current highlight and 'input' selection changes accordingly. problem is that I have 3 different that do the same and with my code all the 3 forms are affected rather one. How do i limit my changes to only be contained to that form. Here is some code for clarification ' <form> ... <h2 onclick="document.getElementById(1001).checked='True' $('h2').removeClass('selected'); $(this).addClass('selected'); "> CONTENT <input type="radio" name="radio" id="1001" value="1001" /> </h2> ... </form>

    Read the article

1