Results 1 to 3 of 3
  1. #1
    Join Date
    May 2006
    Posts
    1,797
    Tokens
    0

    Latest Awards:

    Default making divs visible?

    Hey

    I know this will probably be really simple JS but i just cant figure it out..

    I have this hidden div..

    HTML Code:
    <div style="display:none;" id="content">Content...</div>
    Does anyone know what the javascript would be to make it visible?

    I was thinking about making the height = 0px and width = 0px so it wouldnt mess up the page layout. But does anyone know how to make it visible/another way to do it..

    (Like a better styled popup window)

    And NO DHTML DD LINKS PLS.
    Coming and going...
    Highers are getting the better of me

  2. #2
    Join Date
    May 2005
    Location
    San Francisco, CA
    Posts
    7,160
    Tokens
    2,331

    Latest Awards:

    Default

    HTML Code:
    <html>
    <head>
    <script type="text/javascript">
    <!--
    
    function hi(div)
    {
    
        document.getElementById(div).style.display = "block";
    
    }
    
    //-->
    </script>
    </head>
    
    <body>
    
    <div style="display:none;" id="content">Content...</div>
    <br />
    <a onClick="hi('content');">show</a>
    
    </body>
    </html>

  3. #3
    Join Date
    May 2006
    Posts
    1,797
    Tokens
    0

    Latest Awards:

    Default

    O.o

    Knew it would be that simple rofl

    ty Simon
    Coming and going...
    Highers are getting the better of me

Posting Permissions

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