JQuery Load and missing data
in Using jQuery
•
7 years ago
Hello !
I have a webpage containing lots of php and JQuery code. From this webpage, I use the Load function to open popup window and load webpages inside it.
I noticed that, randomly, I get some console error about "typos" in the code when opening the webpage, like "var foo 10" instead of "var foo = 10". Weird thing is, what's really in the webpage is "var foo = 10".
When I check the post performed when the load function is fired, I can see it load the page with missing/modified data randomly, causing errors.
I tried to place all the javascript code from the loaded page in the main page using the live() of JQuery for firing events, it tend to reduce the number of time I'm getting the issue, but from time to time I'm getting this strange behavior.
I also tried to delay the load function with some kind of throttle, but it hasn't changed anything.
Any idea how I could troubleshoot that ?
Thanks !
1