Creating and Updating a Local File via AJAX/PHP

Get help using Construct 2

Post » Fri Sep 13, 2013 2:08 am

Hello, everyone.

I've been trying to figure out if it's possible for the web version of a game to access local file systems for the purpose of save files as well as a textual log handled via PHP scripts to keep track of how the player approached a level. At the moment, I'm struggling to implement the AJAX object documented here: https://www.scirra.com/manual/107/ajax

That manual page mentions what we want to do, but says that I would need to modify the server hosting the game to allow for cross-domain scripting. Is there an alternative option if I don't have regular access to the server's HTML? I found some other people asking similar questions in the forums and on other websites, but the majority of them seemed to pursue a different avenue like a Google Chrome extension that enables cross-domain scripting for all of your browsing, which I don't think should be a requirement for the game's players.

I would share the relevant portions of the project, but it's really not much. I'm just trying to find a test script file on localhost at the moment and it doesn't do anything yet because it pops up with the different origin error. Maybe someone can point me to an example I missed about something similar.

As an aside, I did also read about the Node-Webkit option for a pure desktop application and that does have the functionality I would like, but I would only like to pursue that if it isn't feasible for the web version to save locally; mainly because the ability to experience everything on my web site is one of my primary goals for this project.

Thanks in advance for any help!

Sincerely,
ObsidianObsidianSpire2013-09-13 02:13:00
B
3
Posts: 5
Reputation: 210

Post » Thu Sep 19, 2013 1:31 am

Any ideas?
B
3
Posts: 5
Reputation: 210


Return to How do I....?

Who is online

Users browsing this forum: Baidu [Spider], pmerineau, tarek2 and 20 guests