browser back button and ajax

Notice: This thread is very old.
aeon
Member | 6
+
0
-

Hi to all, who using this awesome framework!

Working on website, that orientied to be – online-store (online-shop).
Using ajax, to bring life in catalogue page. When user clicks on category, or chosing another page, ajax do, what it should.

But, when user goes from one presenter to another and then going back, using browser's back-button, there it goes – oops… and user is seeing only snippets content, that was sended by server to browser. Sometimes this happening, sometimes not.

Im using jquery.nette.js in my project. This script was retrieved from examples of Nette. (Fiften example).

I think, that you can't help me with solving this problem (maybe I'm wrong), people, can someone give me articles about using ajax in this framework?

Thanks to all, who even read this!

redhead
Member | 1313
+
0
-

Can you try this other script for AJAX? It's a bit complex but give it a try. See docs on history handling.

petr.pavel
Member | 535
+
0
-

Do you develop on one server and then deploy on another? If so, is this happening on both servers? (I'm trying to figure out if it's server-specific.)

Did you try more than one browser? (Maybe it's related to HTTP headers and some browsers treat them differently.)

Try turning on Console and Network panes in Firebug to see if there's anything fishy about the AJAX requests.

aeon
Member | 6
+
0
-

redhead, petr.pavel:

Thanks for advice, i will gather information about that, and will try to merge project with nette.ajax.js

Will report in any cases.

smutko8882
Member | 4
+
0
-

same problem here… i have ajax paginator on page everything works great but if I click on other page in menu and go back to last ajax request i can only see the source of snippet. I'm using nette.ajax.js