AJAX Example with Construct 2

6

Index

Stats

23,759 visits, 72,225 views

Tools

License

This tutorial is licensed under CC BY 4.0. Please refer to the license text if you wish to reuse, share or remix the content contained within this tutorial.

Published on 14 Sep, 2011. Last updated 19 Feb, 2019

Download

Here are the work files:

http://www.jtadeo.com/scirra/ajax/ajaxexample1/ajaxexample1tut.zip

Things to keep in mind and to simplify this example:

1. Keep the files on the same server. Otherwise, you will need to set up a crossdomain policy.

2. Test out the page that calls are being made to. It's critical that there is actual output being generated. Otherwise an error is thrown.

3. Unless you have a local install of WAMP or other local server, you will not be able to test it using the default Construct 2 previews.

This AJAX example tutorial can form the basis for more complex data getting calls that are handled on the server side. At some point, you may one day need to parse data that gets returned. That requires a bit more work and that can be the next tutorial.

Happy HTML5 'ling...erm or something like that.

...sip....

*Hi Guys, check out the thread below, one of our members Ize has provided an example of high scores along with other cool stuffs:

http://www.scirra.com/forum/topic45860_post287339.html#287339

  • 0 Comments

Want to leave a comment? Login or Register an account!