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 7 of 7
  1. #1
    Regular Coder
    Join Date
    Jul 2002
    Location
    Iran
    Posts
    695
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Showing the page when everything is loaded

    Hi, is it possible that I do something that the clients do not see anything on their screens until all my page is downloaded? And is this a good thing to do?! ( well, it's a little bit mysterious!)

  • #2
    Regular Coder martin_narg's Avatar
    Join Date
    Jul 2002
    Location
    Chamonix, France
    Posts
    600
    Thanks
    1
    Thanked 3 Times in 3 Posts
    Hope this helps:

    <html>
    <head>
    <script>
    function init() {
    if( document.all )
    document.all["splashScreen"].style.visibility = 'hidden';
    else if( !document.all && document.getElementById )
    document.getElementById("splashScreen").style.visibility = 'hidden';
    else if( document.layers )
    document.splashScreen.visibility = 'hidden';
    }
    </script>
    </head>
    <body onload="init()">
    <script>
    document.writeln('<div id="splashScreen" style="position:absolute; left:0; top:0; width:'+((document.layers)?screen.width:'100%')+'; height:'+((document.layers)?screen.height:'100%')+'; visibility:visible; z-index:100; layer-backround-color:black; background-color:black;">');
    document.writeln('<table width="'+((document.layers)?screen.width:'100%')+'" height="'+((document.layers)?screen.height:'100%')+'">');
    document.writeln('<tr>');
    document.writeln('<td align="center" valign="middle">');
    document.writeln('<font color="black">Loading...</font>');
    document.writeln('</td>');
    document.writeln('</tr>');
    document.writeln('</table>');
    document.writeln('</div>');
    </script>
    </body>
    </html>
    "Cos it's strange isn't it. You stand in the middle of a library and go 'Aaaaaaaaaaaaaaaaggggggghhhhhhh!'
    and everybody just stares at you. But you do the same in an aeroplane, and everybody joins in."
    -Tommy Cooper

  • #3
    Regular Coder martin_narg's Avatar
    Join Date
    Jul 2002
    Location
    Chamonix, France
    Posts
    600
    Thanks
    1
    Thanked 3 Times in 3 Posts
    if it's an asp page page, just put:

    <%Response.Buffer=false%>

    at the top of the page
    "Cos it's strange isn't it. You stand in the middle of a library and go 'Aaaaaaaaaaaaaaaaggggggghhhhhhh!'
    and everybody just stares at you. But you do the same in an aeroplane, and everybody joins in."
    -Tommy Cooper

  • #4
    New Coder
    Join Date
    Jul 2002
    Posts
    20
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Just make sure that the page loads quickly, so people don't give up on it.

  • #5
    Regular Coder
    Join Date
    Jul 2002
    Location
    Iran
    Posts
    695
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Well, thanx, it's not an asp page martin, and the page doesn't have much contents that it comes up slow, anyway, thanx.

    PS: Is there any book or something talking about these kinda, well, tricks in DHTML? I dunno much about layers and making preloaders & ....., how can I get my hands dirty?! Any applicable magazine, book or ....??

  • #6
    Regular Coder martin_narg's Avatar
    Join Date
    Jul 2002
    Location
    Chamonix, France
    Posts
    600
    Thanks
    1
    Thanked 3 Times in 3 Posts
    Hmm, there's a few good books out there on DHTML/Javascript. O'Reilly's DHTML reference springs to mind quite quickly, but really they guides, special editions etc only show a limited number of examples or "tricks" ( ) Your best bet is with script libraries, http://www.dynamicdrive.com http://www.javascript.internet.com both of these have a fair number of editable scripts. For an online JavaScript reference, I find that devguru.com is hard to beat (http://www.devguru.com/Technologies/...ipt_index.html) they also have a CSS (style sheets) reference, although this is a bit outdated (http://www.devguru.com/Technologies/...css_index.html). At devguru (http://www.devguru.com) they also have tutorials to learn about some of the common internet languages.

    For a really good series of tutorials, http://www.dansteinman.com/dynduo/ is fantastic although quite nerdy.

    There's a lot of reading there I know, most of the devguru.com stuff is really like a javascript dictionary, tutorials can be found anywhere on the net, and javascript snippets at dynamicdrive or javascript.internet.com are easily configured and implemented.

    Hope this helps

    Martin
    "Cos it's strange isn't it. You stand in the middle of a library and go 'Aaaaaaaaaaaaaaaaggggggghhhhhhh!'
    and everybody just stares at you. But you do the same in an aeroplane, and everybody joins in."
    -Tommy Cooper

  • #7
    Regular Coder
    Join Date
    Jul 2002
    Location
    Iran
    Posts
    695
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Thanx martin, you're cool, I'm gonna take a look at them....


  •  

    Posting Permissions

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