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
    Jul 2003
    Location
    Ontario, Canada
    Posts
    129
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Dynamically inserting new table rows... (Node ?)

    Ok, example.

    Code:
    <table>
    <tr><td>
    1.
    </td><td>
    Sample 1
    </td></tr>
    <tr><td>
    2.
    </td><td>
    Sample 2
    </td></tr>
    <tr><td colspan="2" align="right">
    <a href="#" onClick="insertNewRow(); return false;">Click to add a new row</a>
    </td></tr>
    </table>
    I'd like to be able to click the link and insert a table row right above it (after # 2).

    Any suggestions? I've been reading some stuff about Nodes, would this apply??

    Thanks

    IC

  • #2
    Regular Coder
    Join Date
    Jul 2003
    Location
    Ontario, Canada
    Posts
    129
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Anyone?

  • #3
    Senior Coder
    Join Date
    Jul 2004
    Location
    New Zealand
    Posts
    1,315
    Thanks
    0
    Thanked 2 Times in 2 Posts
    This type of thing has been done many, many, many times before on these boards. Try doing a search.
    Forget style. Code to semantics. Seperate style from structure, and structure from behaviour.
    I code to specs, and test only in Firefox (unless stated otherwise).

  • #4
    Regular Coder
    Join Date
    Jul 2003
    Location
    Ontario, Canada
    Posts
    129
    Thanks
    0
    Thanked 0 Times in 0 Posts
    oh hey... thanks :P

    I did do a search

  • #5
    Senior Coder
    Join Date
    Jul 2004
    Location
    New Zealand
    Posts
    1,315
    Thanks
    0
    Thanked 2 Times in 2 Posts
    Quote Originally Posted by IdentityCrisis
    oh hey... thanks :P

    I did do a search
    I find that very hard to believe because otherwise you would have very quickly found this thread on how to insert a new table row
    Forget style. Code to semantics. Seperate style from structure, and structure from behaviour.
    I code to specs, and test only in Firefox (unless stated otherwise).

  • #6
    Regular Coder
    Join Date
    Jul 2003
    Location
    Ontario, Canada
    Posts
    129
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Thanks for your help.

    IC


  •  

    Posting Permissions

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