You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@myfaces.apache.org by Madan Narra <ma...@gmail.com> on 2007/06/11 13:29:55 UTC

[ Tobago ] Issues with Back Button

Hi All,

I have an issue with Back Button when used in IE and FireFox.

When i navigate to the pages and click on Back Button in FireFox , I get a
alert message " The Page you are trying to view Contains POSTDATA that has
expired from cache. " This is expected behaviour.

But when done the same in IE, when clicked on back button, I get a message
saying "Page is Expired". If i click on refresh, then am getting an alert
message " To display the page, IE needs to resend the data again ".

Cant i get the alert message in IE after i click on back button without
getting "Page Expired" message ?
 Is this browser specific or has it to do anything with Tobago ?

-- 
Regards,
Madan N

Re: [ Tobago ] Issues with Back Button

Posted by Thomas Spiegl <th...@gmail.com>.
Check the response header's cache-control pragma. If you see something like ...

Cache-Control	no-store, no-cache, must-revalidate, max-age=0
Pragma  no-cache

then browser side caching is disabled and the browser (firofox, IE,
...) has to reload the page you navigated to via back button. The only
way to show this page is to repost the data to the server. That's why
you get this warn message.

Instead you may set a max-age property for a jsf response:

HttpServletResponse response = (HttpServletResponse) servletResponse;
response.setDateHeader("max-age", 60 * 5); // 5 minutes

this might help.

Thomas

On 6/11/07, Madan Narra <ma...@gmail.com> wrote:
> Hi All,
>
> I have an issue with Back Button when used in IE and FireFox.
>
> When i navigate to the pages and click on Back Button in FireFox , I get a
> alert message " The Page you are trying to view Contains POSTDATA that has
> expired from cache. " This is expected behaviour.
>
> But when done the same in IE, when clicked on back button, I get a message
> saying "Page is Expired". If i click on refresh, then am getting an alert
> message " To display the page, IE needs to resend the data again ".
>
> Cant i get the alert message in IE after i click on back button without
> getting "Page Expired" message ?
>
>
> Is this browser specific or has it to do anything with Tobago ?
>
> --
> Regards,
> Madan N


-- 
http://www.irian.at

Your JSF powerhouse -
JSF Consulting, Development and
Courses in English and German

Professional Support for Apache MyFaces