1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

Link To Make A Website Hide Itself?

Discussion in 'HTML & Website Design' started by GingerApple, Sep 3, 2008.

  1. #1
    Hi!

    I was wondering if anyone knew of a way to make a webpage hide itself, i.e minimise to tray, so that it could be brought up later.

    I would like to implement this feature on one of my websites and was wondering if there was a way for the website to hide itself, like above, on the click of a link.

    Thanks, Will
     
    GingerApple, Sep 3, 2008 IP
  2. nfd2005

    nfd2005 Well-Known Member

    Messages:
    295
    Likes Received:
    20
    Best Answers:
    0
    Trophy Points:
    130
    #2
    You can create pop-under windows, but they would be blocked by most browsers, plus they are annoying.

    You could create an element on your page that "minimizes":

    
    <script>
    var isopen=false;
    function openclose() {
    if (isopen == false) {
    
    document.getElementById('myelement').style.display='';
    isopen=true;
    
    }else{
    
    
    document.getElementById('myelement').style.display='none';
    isopen=false;
    
    }
    
    
    }
    </script>
    
    <div id="myelement" style="display:none;">
    
    This is some information.....
    
    
    </div>
    <a href="javascript:openclose();">Open/Close myelement</a>
    
    
    
    Code (markup):
    This is probably not what you are looking for...
    ... but I figured I would try.
     
    nfd2005, Sep 3, 2008 IP
    GingerApple likes this.
  3. kye172

    kye172 Peon

    Messages:
    147
    Likes Received:
    5
    Best Answers:
    0
    Trophy Points:
    0
  4. GingerApple

    GingerApple Peon

    Messages:
    803
    Likes Received:
    24
    Best Answers:
    0
    Trophy Points:
    0
    #4
    Thanks for trying guys!

    @KYE172 the script isn't working in my IE7 but I'm not after minimising/maximising anyway :)

    @nfd2005 this wasn't actually what I was looking for, but it's given me an idea how to do it a different way! Instead of just hiding the whole window, I could just add that script to hide the information in that window, essentially make it go blank! Excellent! Thanks so much :)
     
    GingerApple, Sep 3, 2008 IP