Java Forums

Main Menu
Home
Today's Posts
FAQ
Search
Contact Us

Java Network
Java Tips
Java Tips Blog

Sponsored Links





Welcome to the Java Forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community, you will:

  • have access to post topics
  • communicate privately with other members (PM)
  • not see advertisements between posts
  • have the possibility to earn one of our surprises if you are an active member
  • access many other special features that will be introduced later.

Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact us.

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 07-09-2008, 10:53 AM
Member
 
Join Date: Jun 2008
Posts: 52
82rathi.angara is on a distinguished road
warning that page has expired and i need to refresh the page again
We have built an dynamic web application. In the application if we use the browser back button or forward button, it shows a warning that page has expired and i need to refresh the page again. Is there any way to avoid this. This problems come in IE6.

Like this
Warning: Page has Expired The page you requested was created using information you submitted in a form. This page is no longer available. As a security precaution, Internet Explorer does not automatically resubmit your information for you.

To resubmit your information and view this Web page, click the Refresh button.

Is there any way to do this.

Help needed
Bookmark Post in Technorati
Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 07-13-2008, 07:02 PM
Nicholas Jordan's Avatar
Senior Member
 
Join Date: Jun 2008
Location: Southwest
Posts: 579
Nicholas Jordan is on a distinguished road
form submit
Quote:
Originally Posted by 82rathi.angara View Post
(...)Is there any way to do this.
Write your own forward and back buttons, just label them forward / back / update or whatever makes sense. Do the logic in the forms handling code. Too many browsers, and each have their own agenda.

It is consequential enought to do forms handling, I would not rely on browser for forward and back control.

Quote:
Originally Posted by 82rathi.angara View Post
Help needed
I get over half of my code for free writing solutions to other people's questions. I wrote a major core component Thur, Fri, Sat that I had made sluggish progress on. I call it LittleBeanTestSuite and WombatKeyControl

( humor folks, humor )

Do you think I need help? If you do, you have been talking to too many interviewers and need to focus on the code base.
__________________
Please provide your feedback on our
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
.
Cybercartography: A new theoretical construct proposed by D.R. Fraser Taylor
Bookmark Post in Technorati
Reply With Quote
  #3 (permalink)  
Old 07-13-2008, 07:52 PM
fishtoprecords's Avatar
Senior Member
 
Join Date: Jun 2008
Posts: 349
fishtoprecords is on a distinguished road
Quote:
Originally Posted by 82rathi.angara View Post
We have built an dynamic web application. In the application if we use the browser back button or forward button, it shows a warning that page has expired and i need to refresh the page again. Is there any way to avoid this.
This is not a problem, its a feature.

Why do you consider it a problem, this is how the Web works.

Building applications that do what you want, and still let the user use the browser's back and forward buttons has been a challenge from the beginning. Its a feature. Its why we developers get paid big bucks.
Bookmark Post in Technorati
Reply With Quote
  #4 (permalink)  
Old 07-15-2008, 01:40 PM
Member
 
Join Date: Jun 2008
Posts: 52
82rathi.angara is on a distinguished road
This is no-cache problem?
Quote:
Originally Posted by fishtoprecords View Post
This is not a problem, its a feature.

Why do you consider it a problem, this is how the Web works.

Building applications that do what you want, and still let the user use the browser's back and forward buttons has been a challenge from the beginning. Its a feature. Its why we developers get paid big bucks.


ya ...you are saying right that this is not problem . But we need Solution when i return to shop cart page to product page and again go to shop cart page ....this warning page come........

Somebody told me that this is no-cache problem . I put some code in our java file.
Like this:
public class AntiCacheFilter implements Filter {
public void destroy() {}

public void doFilter(ServletRequest request, ServletResponse response,
FilterChain chain) throws IOException, ServletException {
if (response instanceof HttpServletResponse) {
((HttpServletResponse) response).setHeader("Cache-Control",
"no-cache, must-revalidate");
((HttpServletResponse) response).setHeader("Pragma", "No-cache");
((HttpServletResponse) response).setDateHeader("Expires", 1L);
}

chain.doFilter(request, response);
}

public void init(FilterConfig config) throws ServletException {}
}




I added this code
((HttpServletResponse) response).setHeader("Pragma", "No-cache");
((HttpServletResponse) response).setDateHeader("Expires", 1L);
in file .But No solution.....
Bookmark Post in Technorati
Reply With Quote
  #5 (permalink)  
Old 07-15-2008, 02:45 PM
fishtoprecords's Avatar
Senior Member
 
Join Date: Jun 2008
Posts: 349
fishtoprecords is on a distinguished road
Quote:
Originally Posted by 82rathi.angara View Post
ya ...you are saying right that this is not problem . But we need Solution .
The phrase "its not a problem, its a feature" is an idiom. You have a problem, but the system is working as designed. Its a feature.

If your problem space requires different actions, you have to implement it all, because the browsers are working properly per the spec.
Bookmark Post in Technorati
Reply With Quote
  #6 (permalink)  
Old 07-15-2008, 02:48 PM
fishtoprecords's Avatar
Senior Member
 
Join Date: Jun 2008
Posts: 349
fishtoprecords is on a distinguished road
Quote:
Originally Posted by 82rathi.angara View Post
Somebody told me that this is no-cache problem .
They didn't steer your correctly. Its a feature of POST.

no-cache is not going to help. Even if you had a no-cache problem, the directives are hints not rules. The browser may chose to pay attention, or may ignore it.
Bookmark Post in Technorati
Reply With Quote
Sponsored Links
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Refresh the page udhayageetha AWT / Swing 2 07-01-2008 10:03 AM
Go back to previous page using session in JSP page gopikarikati009 JavaServer Pages (JSP) and JSTL 0 04-27-2008 05:38 AM
How to Refresh the same page by JSP AbuAziz JavaServer Pages (JSP) and JSTL 2 12-10-2007 05:06 AM
How to run jsp page nikisonproblem New To Java 1 07-09-2007 04:16 PM
warning: page has expired Peter Web Frameworks 2 07-04-2007 08:45 AM


All times are GMT +3. The time now is 03:16 AM.


VBulletin, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright ©2006 - 2007, www.java-forums.org