Results 1 to 2 of 2

Thread: Call to PHP file Delays Page from Loading

  1. #1
    Join Date
    Mar 2009
    Location
    San Diego, CA
    Posts
    5
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Default Call to PHP file Delays Page from Loading

    For the header on my web site at http://thebestplacesinsandiego.com I include weather information.

    The weather information is pulled in to the header from a separate php file using

    <?php require($DOCUMENT_ROOT . "http://thebestplacesinsandiego.com/wp-content/themes/default/test_weather_style.php5"); ?>

    It takes a few seconds for the weather to load. As a result, the rest of my page is held up from loading as well.

    What can I do so the rest of the page does not wait for the weather information to load?

    I've looked at ways to 1. have the weather information load last and 2. have the weather information only load on the first page visit and then not reload on subsequent pages. Unfortunately, I haven't figured out a workable solution. So, I'd appreciate any details you could provide to figure out an answer to this challenge. Thank you.
    Last edited by wilm1998; 03-22-2009 at 02:35 PM.

  2. #2
    Join Date
    Mar 2009
    Location
    San Diego, CA
    Posts
    5
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Default

    I finally figured to put the code in my footer and then use css to have it appear in the header. This way the full page loads immediately and the weather loads last.

Bookmarks

Posting Permissions

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