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 12 of 12
  1. #1
    New Coder
    Join Date
    Jan 2003
    Posts
    15
    Thanks
    0
    Thanked 0 Times in 0 Posts

    pop up - tab windows

    A number of sites have pop up windows with Tabs, which look extremely good and operate very well e.g the site http://www.dabs.com/home.asp has product information displayed in this fashion. The BBC also used them for census figures.

    Does anybody know if this done by an applet and if so is there somewhere to get the required code?

  • #2
    Regular Coder
    Join Date
    Aug 2002
    Location
    Spain
    Posts
    420
    Thanks
    0
    Thanked 0 Times in 0 Posts
    You only have to use layers and a simple hide/show javascript function. That's all, no applets.
    Don't resist to assimilation. Billions of Borgs can't be wrong!

  • #3
    New Coder
    Join Date
    Jan 2003
    Posts
    15
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Dear Bjorn, with 6 or seven Wimbledon titles to your name you are entitled to sound a bit uppity, but could you also direct me to a good site with source code - the examples I have seen have it hidden?

  • #4
    Regular Coder
    Join Date
    Aug 2002
    Location
    Spain
    Posts
    420
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Bjorn? wimbledon? sorry, I think that I don't understand you.

    Anyway. You can see the source code of the popups in dabs.com; it's not hidden: just press the right mouse button and select "View source code", but as I said is as simple as hiding/showing layers
    Don't resist to assimilation. Billions of Borgs can't be wrong!

  • #5
    New Coder
    Join Date
    Jan 2003
    Posts
    15
    Thanks
    0
    Thanked 0 Times in 0 Posts
    thanks for that - got it at last.

    re. Bjorn - see http://www.bjornborg.20m.com/

  • #6
    Regular Coder
    Join Date
    Aug 2002
    Location
    Spain
    Posts
    420
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Bjorn Borg. lol
    Don't resist to assimilation. Billions of Borgs can't be wrong!

  • #7
    Senior Coder
    Join Date
    Jun 2002
    Location
    The Netherlands, Baarn, Ut.
    Posts
    4,253
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Layers?

    Borgtex,

    what do you mean by "layers" in this context? Surely not the layer element? By the way, where are these so-called "pop-ups" to be found? I'm puzzled...
    Regards,
    Ronald.
    ronaldvanderwijden.com

  • #8
    Regular Coder
    Join Date
    Jun 2002
    Location
    NL
    Posts
    421
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Ronald, scroll down on that page and click on the red buttons below "Newsdesk".
    It's something like this:
    Code:
    <html>
    <head>
    <title></title>
    <script type="text/javascript">
    var prevDiv = null;
    function showit(theDiv){
    if (prevDiv != null){
    eval("document.all." + prevDiv + ".style").visibility = "hidden";}
    eval("document.all." + theDiv + ".style").visibility = "visible";
    prevDiv = theDiv;}
    </script>
    <style type="text/css">.tab {position:absolute;visibility:hidden;}</style>
    </head>
    <body>
    <a href="javascript:showit('aa');">aa</a>
    <a href="javascript:showit('bb');">bb</a>
    <a href="javascript:showit('cc');">cc</a>
    <a href="javascript:showit('dd');">dd</a>
    <a href="javascript:showit('ee');">ee</a><br>
    <div id="aa" class="tab">aa</div>
    <div id="bb" class="tab">bb</div>
    <div id="cc" class="tab">cc</div>
    <div id="dd" class="tab">dd</div>
    <div id="ee" class="tab">ee</div>
    </body>
    </html>

  • #9
    New Coder
    Join Date
    Jan 2003
    Posts
    15
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Ronald, any chance you could just add in whatever bit is required to make your eg code above work ,when I run it - it seems to want to load a nonexistent page instead of just showing what is below the tab text that I have added?

  • #10
    Regular Coder
    Join Date
    Jun 2002
    Location
    NL
    Posts
    421
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Kokane, go to this page: http://www.dyn-web.com/dhtml/show-hide.html
    and click on the Show/Hide layers link for an example

  • #11
    New Coder
    Join Date
    Jan 2003
    Posts
    15
    Thanks
    0
    Thanked 0 Times in 0 Posts
    THANKS & GOODNIGHT

  • #12
    Senior Coder
    Join Date
    Jun 2002
    Location
    The Netherlands, Baarn, Ut.
    Posts
    4,253
    Thanks
    0
    Thanked 0 Times in 0 Posts

    divs, not layers

    Ah, so we're talking about divs who's visibility is turned on and off. Got it.
    Regards,
    Ronald.
    ronaldvanderwijden.com


  •  

    Posting Permissions

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