Refresh window depending on another file being mod

Results 1 to 2 of 2

Thread: Refresh window depending on another file being mod

  1. #1
    Join Date
    Dec 1969

    Default Refresh window depending on another file being mod

    Help, I&#039m trying to refresh a web page by calling a Javascript function once every 2 mins and when the function is called I want to check the modified datetime of another file on the web server, and if the datetime has changed since it was last checked, I want to reload the web page. I know you can use datelastmodified from ASP but I can&#039t pass the info to the javascript for comparison purposes.<BR>I&#039m quite new to ASP but this is really baffling me at the moment, any help would be much appreciated. Someone mentioned http request to solve this but I don&#039t know how to do this either.

  2. #2 Guest

    Default RE: Refresh window depending on another file being

    I think that what you are trying to do is to execute a server-side operation on the client. It does not seem make much sense. Much simpler to just use:<BR><BR>&#060;META HTTP-EQUIV="REFRESH" CONTENT=120&#062;<BR><BR>This line added to the &#060;head&#062;&#060;/head&#062; section of the page you want to refresh, and it will be refreshed every 120 seconds (unconditionallY).<BR><BR>You might be able to use the <BR><BR>&#060;META HTTP-EQUIV="Expires"CONTENT="Tue, 04 Dec 1996 21:29:02 GMT"&#062;<BR><BR>to control whether is reloaded from the server everytime.<BR><BR>I am not an expert on headers, but you may be able to do more reseach on them to find just what you want.<BR><BR>This approach would require less programming, which is a good thing as less programming reduces the complexity of your site.

Posting Permissions

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