Nitin wrote:
> Hi Friends,
>  
> I want your help.
> I have a webpage with two frames.
> When I click on the button on one frame it shows me the result (that is 
> a perl-cgi file) on the second but the problem is that it is showing the 
> old page (taking from the cache).
>  
> Is there any way in perl to load a fresh page in that frame.

Here are my cache notes:

Example HTTP 1.0 headers

        Expires: Tue, 08 Apr 1997 17:20:00 GMT
        Expires: 0
        Pragma: no-cache

Example HTTP 1.1 headers

        Cache-Control: must-revalidate
        Cache-Control: max-age=3600
        Cache-Control: no-cache

Stop caching:

Try outputting one/both of these headers:
Using HTTP/1.0:
        print "Pragma: no-cache\n";
Using HTTP/1.1:
        print "Cache-control: no-cache\n";

Try expiry headers using both the Date and Expires header
(the server may fill in the Date: for you).

        print "Date: [HTTP date]\n";
        print "Expires: [HTTP date]\n";

Sample code snipped from posts:

        print STDOUT <<"EOD";
HTTP/1.1 200 OK
Date: $date
Content-type: $content_type
Content-length: $content_length
Pragma: no-cache
Cache-control: no-cache
Expires: now

EOD

The first line may/may not be needed and naturally you have to build
the vrbls used according to HTTP specs.  If all of that won't get it
nothing will.  :)

Or you can return HTML to do this sort of thing:

HTML versions:

<META HTTP-EQUIV="pragma" CONTENT="no-cache">
<META HTTP-EQUIV="Expires" CONTENT="Tue, 26-Oct-1965 12:00:00">
<META HTTP-EQUIV="Expires" CONTENT="NOW">
<META HTTP-EQUIV="last modified" CONTENT="NOW">


-- 
   ,-/-  __      _  _         $Bill Luebkert   ICQ=162126130
  (_/   /  )    // //       DBE Collectibles   Mailto:[EMAIL PROTECTED]
   / ) /--<  o // //      http://dbecoll.tripod.com/ (Free site for Perl)
-/-' /___/_<_</_</_     Castle of Medieval Myth & Magic http://www.todbe.com/

_______________________________________________
Perl-Unix-Users mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs

Reply via email to