473,396 Members | 1,975 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

when you go back in browser, search results page does not display - how can you prevent?

Say you have three pages, a search page, a results/master, and a detail
page.

You choose parameters on your search page and submit the page.
The results show in the reults/master page.
You click one to go the details page.
You hit the browser button to go back and it shows the results/master page
but shows "Page has expired" error.

How can you prevent this? How can you show the results page whether you get
there forwards or backwards?
Jul 17 '05 #1
4 2564
"NotGiven" <no****@nonegiven.net> wrote in message
news:<IC*****************@bignews3.bellsouth.net>. ..

Say you have three pages, a search page, a results/master, and a detail
page.

You choose parameters on your search page and submit the page.
The results show in the reults/master page.
You click one to go the details page.
You hit the browser button to go back and it shows the results/master page
but shows "Page has expired" error.

How can you prevent this?


You can either allow the results page to be cached or open the detail
page in a new browser window using <a href="detail.php" target=_blank>
or JavaScript. The latter will also allow you to specify the size
of the new window and show it without menu bar and status bar, so
it won't obscure the results window and the user will know they are
in a new window and can return to results by closing the detail window.

Cheers,
NC
Jul 17 '05 #2
how do you specify allowing the page to be cached? Thanks in advance
"Nikolai Chuvakhin" <nc@iname.com> wrote in message
news:32**************************@posting.google.c om...
"NotGiven" <no****@nonegiven.net> wrote in message
news:<IC*****************@bignews3.bellsouth.net>. ..

Say you have three pages, a search page, a results/master, and a detail
page.

You choose parameters on your search page and submit the page.
The results show in the reults/master page.
You click one to go the details page.
You hit the browser button to go back and it shows the results/master page but shows "Page has expired" error.

How can you prevent this?


You can either allow the results page to be cached or open the detail
page in a new browser window using <a href="detail.php" target=_blank>
or JavaScript. The latter will also allow you to specify the size
of the new window and show it without menu bar and status bar, so
it won't obscure the results window and the user will know they are
in a new window and can return to results by closing the detail window.

Cheers,
NC

Jul 17 '05 #3
Nikolai Chuvakhin wrote:
"NotGiven" <no****@nonegiven.net> wrote in message
news:<IC*****************@bignews3.bellsouth.net>. ..
Say you have three pages, a search page, a results/master, and a detail
page.

You choose parameters on your search page and submit the page.
The results show in the reults/master page.
You click one to go the details page.
You hit the browser button to go back and it shows the results/master page
but shows "Page has expired" error.

How can you prevent this?

You can either allow the results page to be cached or open the detail
page in a new browser window using <a href="detail.php" target=_blank>
or JavaScript. The latter will also allow you to specify the size
of the new window and show it without menu bar and status bar, so
it won't obscure the results window and the user will know they are
in a new window and can return to results by closing the detail window.


....or simply have the search form GET instead of POST...

--
Justin Koivisto - sp**@koivi.com
PHP POSTERS: Please use comp.lang.php for PHP related questions,
alt.php* groups are not recommended.
Jul 17 '05 #4
"NotGiven" <no****@nonegiven.net> wrote in message
news:<QO*****************@bignews3.bellsouth.net>. ..

how do you specify allowing the page to be cached?


By sending the appropriate headers to the client. Example:

header('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT');
header('Expires: ' . gmdate('D, d M Y H:i:s', strtotime('+1 hour')) . ' GMT');

This tells the client that the page was last modified when it was
called and will not change for an hour. So a smart client would
cache the page at the first load and won't attempt to load it again
if it visits it within an hour, but rather load a cached copy.

A word of caution: assuming a client is smart can lead to frustrating
results...

Cheers,
NC
Jul 17 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

16
by: Dave Smithz | last post by:
Hi, In summary: I want to a form to submit information via a HTTP POST, however, when using Internet Explorer I want to be able to use the back button and all the information retained....
8
by: Galina | last post by:
Hello I have 6 dependent list boxes on my ASP page:  Faculty;  Lecturer;  Course;  Course occurrence;  Group;  Week commencing date. When faculty is selected, lists of lecturers and...
5
by: Dan | last post by:
Hi, I'm going crazy here, please help. I have a parent page that has a user control on it that bubbles up data from a dropdown menu. The drop down menus are populated by a set of radio buttons,...
3
by: Penny Bond | last post by:
Hi, Any help or suggestions on this one would be gratefully appreciated: I have 2 aspx pages one is called 'Query' and the other 'Details'. Query page has a number of text boxes and drop...
6
by: guoqi zheng | last post by:
In a regular html form, when user press "enter" key, the form will be submitted. However, in ASP.NET web form, a form will only be submitted (post back) when a special button is clicked. Many...
11
by: Joe | last post by:
Hello All, I have an ASP.NET page with one Textbox (SearchTextBox) and one ImageButton (SearchButton) server controls. The user can type search text in SearchTextBox and click SearchButton and...
4
by: Sarvesh997 | last post by:
Hi, I have one problem regarding search & search results page in IE & Firefox. A code in both pages written in Php & database in MySQL Problem : When i selected one or more checkbox &...
6
by: lucyh3h | last post by:
Hi, In one of my pages, I use javascript (AJAX) to populate one mulitple select field based on user's click event on another control. I noticed that when I navigate back to this page by clicking...
1
by: terryshamir | last post by:
Hi - I'm doing my first ASP project. In my App I present one asp page with parameters for a search (search.asp) - when they do a search the form is posted to another ASP page...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.