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 3 of 3
  1. #1
    New to the CF scene
    Join Date
    Jul 2007
    Posts
    7
    Thanks
    0
    Thanked 0 Times in 0 Posts

    simple show hide table problem

    hey guys, i dont know if this is php or not
    i just need to know:

    if i have a table with only 2 rows, and in the top row is an image, banner size,
    is there a way to make it so that when the banner image is clicked the bottom row of the table is completely hidden along with all of its content?

    is there a way to make it hidden when the page is first entered, and then can hide and show when clicked?

    PLEASE if you can answer this do so i beg of you all, lol!

  • #2
    Regular Coder
    Join Date
    Jul 2007
    Location
    UK
    Posts
    223
    Thanks
    0
    Thanked 14 Times in 14 Posts
    Yes what you want to do is achievable in javascript.

    You can attach an onclick event handler to any element, e.g. a table row, an image, etc.
    You can hide an element by setting the "display" property to "none" and then to display the element again set the display property to "block" (or "" might want to check the documentation on that).
    If you want the second row hidden when the page is opened you can add an "onload" event handler to call a function that will hide the second row.

  • #3
    New to the CF scene
    Join Date
    Jul 2007
    Location
    Tiruvannamalai
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Hi,

    Can u send me the code plz,


  •  

    Posting Permissions

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