views:

88

answers:

1

Hi, I've got two scripts: 1.php and 2.php. Here they are:

1.php

<?php

header('Pragma: no-cache');
header('Cache-Control: max-age=1; no-cache');
header('Expires: Tue, 1 May 1985 01:10:00 GMT');
header('ETag: "'.md5(rand(1, 1000)).'"');

print date('H:i:s');
?>
<a href="2.php">pay</a>

2.php

<a href="javascript:history.back()">back</a>

Visitor lands on 1.php and then goes to 2.php. I want browser to re-request 1.php after vistor's click on "back" link. Currently, it doesn't work. How it can be managed?

upd. I can edit 1.php ONLY and cant edit 2.php.

A: 

In practice you can't. Although browsers should send a new request for a non-cacheable page (ther are several things broken in the headers you are sending) both MSIE and Firefox will always use an in-memory copy within a certain timescale.

C.

symcbean