Submit Your Article Forum Rules

Results 1 to 2 of 2

Thread: Refresh page automatically on arrival

  1. #1
    Senior Member Milo's Avatar
    Join Date
    Nov 2004
    Posts
    236

    Refresh page automatically on arrival

    Hi all,
    Thought this would be a quick find, but have had no luck yet. I'm looking for a code (not meta) that refreshes the content of my page on arrival. We constantly update our homepage (daily, not every minute) with new products. Although not very often, we do have some of our shoppers ordering products that were taken down a while ago. I did find a meta code that can refresh the page constantly, but you have to specify increments and its continuous, I only want it done once. Also, further research of this meta code has shown that search engines don't like this code.
    Any info will be helpfull.
    Cheers.
    Miles

  2. #2
    Are you using any server side code or just plain html?

    The best way to do this is to ensure that the page does not get cached. Your solution of "refreshing once" is proablaby not the best way to do this and may be the cause of your not finding anything. Do a search for "prevent page caching" or something similar.

    If you are using ASP, you can add a line to the top of the page:

    Code:
    <% Response.ExpiresAbsolute=#Jan 01, 1980 00:00:00# %>
    There are other methods, to prevent caching. I think including Meta tags, but not content-refresh (or whatever it is).

    If you REALLY have to do a new page load, you could do it like this (with either server side or client side script):
    1) User comes to www.site.com/default.asp
    2) Script checks for existance of query string with variable "time"
    3) The first page view, the script will not find this variable
    4) Redirect to www.site.com/default.asp?time=[currentTime]
    5) Script now finds appropriate variable in the querystring and displays the page

    This is almost the same as not caching, since the browser has never seen this page with [currentTime] in the query string.

Similar Threads

  1. The frequency of page refresh
    By Simon Young in forum Google Discussion Forum
    Replies: 4
    Last Post: 04-02-2010, 08:25 PM
  2. Close a child page and refresh parent page
    By getmea in forum Web Programming Discussion Forum
    Replies: 16
    Last Post: 02-06-2010, 11:19 PM
  3. Page refresh and screenreader users issue
    By Webnauts in forum Accessibility and Usability Forum
    Replies: 2
    Last Post: 05-03-2006, 12:48 PM
  4. How do I force the page to refresh from the server?
    By zwickes in forum Web Programming Discussion Forum
    Replies: 2
    Last Post: 11-21-2004, 12:34 PM

Posting Permissions

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