Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Which browsers' back button does not generate request to the server?

I need to test my web application against a browser for which back button doesn't generate request to server.

Could you give me examples of such browsers?

like image 857
wheleph Avatar asked Apr 27 '10 14:04

wheleph


People also ask

Are all browser requests GET requests?

Yes. By default, if you type in address bar or click any link, then it will be a GET call.

Do browsers make GET requests?

The browser per default makes GET requests since that is what it is doing, it is getting stuff. POST-requests can be made from the browser using javascript (ie XHR/Fetch) or when using html forms with the method-attribute.

What happens when browser Back button is pressed?

Your browser keeps a stack of records showing which pages you've visited in the current window's session. When you press the back button on your browser, it goes to the last page in that stack.

Where does the browser send the request?

The browser sends an HTTP request message to the server, asking it to send a copy of the website to the client (you go to the shop and order your goods). This message, and all other data sent between the client and the server, is sent across your internet connection using TCP/IP.


2 Answers

That doesn't depend on the browser used, but on the HTTP response headers sent to it. If the browser is by the response headers instructed to cache the page, then it will cache the page. But if it is instructed to not cache the page, then it will not cache the page and fire a real request.

You have control over the response headers on the server side.

like image 107
BalusC Avatar answered Nov 15 '22 08:11

BalusC


Internet explorer 6, not sure about 7/8. Make sure you dont have the following meta statements in your header (they will force page reload):

<META HTTP-EQUIV="Pragma" CONTENT="no-cache">
<META HTTP-EQUIV="Expires" CONTENT="-1">

Check this page for more info:

http://support.microsoft.com/kb/234067

like image 36
Luis Avatar answered Nov 15 '22 06:11

Luis