Re: [Phplib-users] page expiry problems
Brought to you by:
nhruby,
richardarcher
From: Layne W. <la...@dr...> - 2003-07-01 02:50:57
|
>> I have a situation where it is easier to generate a static html page >> with >> php code (much repetition). The problem is that repeat visits to the >> same >> page within one browser session is causing the page to be retrieved >> from >> server each time it is viewed. I would like the page to be handled >> like a >> static page, based on the file's timestamp on server (since the page >> is >> indeed 'static'). > > There is no "page" on the server, only a PHP script. > > Simple fix: > > Backup your PHP script (important!) > Load the page in your browser > View Source > Select All > Copy > Open the original script > Select All > Paste > Save This is one of the main reasons I have a copy of PHP compiled for command line usage: $ ./create_some_page.php > some_page.html Start the script with #!/usr/local/bin/php -q and make sure it is executable. Layne Weathers |