rpdjf's Forum Posts

  • 2 posts
  • You can use logcat to get logs from an android app. Add console logging actions to your code, for example:

    Browser Log "AJAX Requesting data"

    Browser Log "AJAX Response: "&sJsonValue

    console.log("aTemp=" + JSON.stringify(aTemp))

    Add "AJAX On Error" event and also put some logging into it.

    Export debug apk, run it, grab logcat log from the phone and search for those console messages. Also check if there are any errors or exceptions in the log which happened at the time of AJAX request.

    Thanks, I just figured it out.

    I made my API using PHP, but I just started using php few days ago.

    I had to allow cross-domain on my apiby adding :

    header("access-control-allow-origin: *");

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Hello,

    I've made an api that allows me to get a leaderboard and post highscores into my hosted database. I do requests with the Ajax addon, it works well on the PWA (https://play.ruinfo.ch).

    But it's not working when I export my game to apk. I can still send data using api, but I can't get data from api.. It returns nothing.

    I don't even know how to see what's the error code. What should I do ?

    From PWA :

    From Apk :

  • 2 posts