Forum Moderators: phranque

Message Too Old, No Replies

If-Modified-Since and perl/cgi script?

Any way to do this, or fake the date?

         

Jesse_Smith

3:02 am on Nov 9, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Has any one discovered a way to use If-Modified-Since with a cgi/perl file? If not, is there a way to use .htacces and make up a date for a file or every file in the directory? For example, to make a widget.cgi URL always give out

Last-Modified: Sun, 09 October 2003 02:57:21 GMT

so Google never touches the script again?

jdMorgan

8:59 pm on Nov 9, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Jesse_Smith,

You could try this:


<Files your-cgi-script.pl>
Header set Last-Modified: "Sun, 09 October 2003 02:57:21 GMT"
</Files>

(See Apache mod_headers [httpd.apache.org])
> so Google never touches the script again?

However, I would not count on this method if it is an absolute requirement that Google never fetch the script again. Normally, they won't re-fetch a page if it hasn't changed since the last time they fetched it. But there's nothing to guarantee that they won't *ever* re-fetch a page.

Jim

Jesse_Smith

9:31 am on Nov 10, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Thanks. Just tried it out, went to the server header section, and it worked! When Google comes by it loves to crash the server. I can take it down when ever I want it to crawl the mod_rewrite pages.

Brett_Tabke

11:00 am on Nov 10, 2003 (gmt 0)

WebmasterWorld Administrator 10+ Year Member Top Contributors Of The Month



Use UnParsed Headers and have the script spit out it's own last mod date.