Post and redirect



I would like to integrate a Gdevelop game into a web page that needs to be redirected based on the game’s choices.
The game is inside a form, in “vanilla” javascript I used a script that creates a button with the data and clicks on it. But in GDevelop i’m newbie and it doesn’t seem to work.
I tried the “send a request” extension which, understandably, sends the data without redirecting the page.
Is there any way to do this?


If the page displaying the game changes, the game is exited, right? :thinking:


Sure, page change and close the game, no problem for this.


GDevelop allows to use javascript snippets, so you should be able to make that redirect work.


Sure. I had already tried to integrate the js code but the game crashes when I run it …
The code (I am attaching it) works when used alone.


Can’t help you much with javascript, I’m afraid, but have you checked ctrl+shift+i? The console tab is sometimes helpful with crashes.