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 Coder
    Join Date
    Apr 2009
    Posts
    63
    Thanks
    2
    Thanked 0 Times in 0 Posts

    Links inactive until complete page load

    I've been working on decreasing page load time and ran into something I can't figure out. The issue is not always the time involved for the page to load completely, but the fact that links and the page scroll bar are inactive until the very last element has loaded. In my case it's usually an Adsense Ad. But I've seen other large pages on other sites with lots of javascript which take just as long to load completely, but, during the process you can still scroll the page or use links. The page is still functional during the process.

    What's the trick?

  • #2
    Regular Coder
    Join Date
    May 2009
    Posts
    813
    Thanks
    123
    Thanked 24 Times in 24 Posts

    re

    Adsense code links to google so you will have to wait for that too load. People use many things to optimise their sites, such as includes and external scripts, small script size etc. It will take some studying if you want to know all the tricks. For a particular site, you need to post the link so I can see what they are doing.

  • #3
    New Coder
    Join Date
    Apr 2009
    Posts
    63
    Thanks
    2
    Thanked 0 Times in 0 Posts
    Hi quartzy,

    I'm having the biggest problem with my site's forums. There are a lot of them.

    Go to www(dot)realworldautomotive(dot)com(forward slash)forums(forward slash)index(dot)com and refresh a few times. See how none of the forum links become active until the top two banners open up. If I use Adsense Ads in the same spots, it's much worse. Those ads are at the end of the body and positioned absolute up top.

    I've been working on page load for a while:

    - Compressed all .js and .css with a YUI Compressor
    - I have this in .htaccess to compress and speed up on my Apache server:

    Code:
    # BEGIN Compress  text files
    <IfModule mod_deflate.c>
      <FilesMatch "\.(css|js|x?html?|php)$">
        SetOutputFilter DEFLATE
      </FilesMatch>
    </IfModule>
    # END Compress  text files
     
    # BEGIN Expire headers
    <IfModule mod_expires.c>
      ExpiresActive On
      ExpiresDefault "access plus 1 seconds"
      ExpiresByType image/x-icon "access plus 2592000 seconds"
      ExpiresByType image/jpeg "access plus 2592000 seconds"
      ExpiresByType image/png "access plus 2592000 seconds"
      ExpiresByType image/gif "access plus 2592000 seconds"
      ExpiresByType application/x-shockwave-flash "access plus 2592000 seconds"
      ExpiresByType text/css "access plus 604800 seconds"
      ExpiresByType text/javascript "access plus 216000 seconds"
      ExpiresByType application/x-javascript "access plus 216000 seconds"
      ExpiresByType text/html "access plus 600 seconds"
      ExpiresByType application/xhtml+xml "access plus 600 seconds"
    </IfModule>
    # END Expire headers
     
    # BEGIN Cache-Control Headers
    <IfModule mod_headers.c>
      <FilesMatch "\\.(ico|jpe?g|png|gif|swf)$">
        Header set Cache-Control "max-age=2592000, public"
      </FilesMatch>
      <FilesMatch "\\.(css)$">
        Header set Cache-Control "max-age=604800, public"
      </FilesMatch>
      <FilesMatch "\\.(js)$">
        Header set Cache-Control "max-age=216000, private"
      </FilesMatch>
      <FilesMatch "\\.(x?html?|php)$">
        Header set Cache-Control "max-age=600, private, must-revalidate"
      </FilesMatch>
    </IfModule>
    # END Cache-Control Headers
     
    # BEGIN Turn ETags Off
    <IfModule mod_headers.c>
      Header unset ETag
    </IfModule>
    FileETag None
    # END Turn ETags Off
     
    # BEGIN Remove Last-Modified Header
    <IfModule mod_headers.c>
      Header unset Last-Modified
    </IfModule>
    # END Remove Last-Modified Header
    - Doing my best to use as few .js and .css links as possible
    - Optimize and give height and width attributes to all images

    My home page is actually larger than the forums, but opens faster. I'm using as little Adsense as possible on the forums. It's seems like I'm right at the borderline where one more Ad slows it down to much.

    Any ideas?


  •  

    Posting Permissions

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