How do I Reapeat an AJAX Request

Get help using Construct 2

Post » Thu Feb 26, 2015 10:15 pm

Hello,

I'm using AJAX/PhP/MySQL, for run my game, so i use some AJAX Request for update my DataBase and maintain her Up to Date,
so the first time i'm ask a request for Create or Delete a char this work but some time not ... So i don't really know if it's because the DB link was close or other thing ...

So be sure the request was complete i would like to know if there is a way for Retry the request until it's done ( and not with the error option, because there is no error ^^ )

Hope you understand !

Thank you =)
B
16
S
4
G
1
Posts: 63
Reputation: 1,131

Post » Fri Feb 27, 2015 12:23 pm

In chrome and FF, hit CTRL SHIFT J for the console.
This should show if your ajax request is actually being made or not.

As for a retry, why not just add a button that on clicked/touched performs the ajax request.

You could go as far as adding an every X seconds have the call performed automatically so you can check the console for problems when called.
Who dares wins
B
56
S
15
G
17
Posts: 1,843
Reputation: 17,287

Post » Sat Feb 28, 2015 5:43 pm

Hello Lennaert,

I have solve the problem ^^' ... The request work correctly the problem come from the Request ^^' ...
I have forget to delete one event that continuously repeat the request hehe ^^' ... So the app never have the time to update the values ^^' ...

Now work correctly,

So i have see your Tut's about the Ajax Pong game and inspire my self for make my request ^^' ... So thank for your help =)
B
16
S
4
G
1
Posts: 63
Reputation: 1,131


Return to How do I....?

Who is online

Users browsing this forum: Evanetot, ItsAstro, Pulstar, wowsoundsg and 3 guests