Transfer JavaScript variable to PHP

Hello @all,

i have a issue transfering a javascript variable(string) to PHP.
My goal is to execute the macro sc_exec_sql with the variable sql3.


Many thanks in advance

You cannot use javascript variable in PHP directly, you can use Ajax or HTML POST OR GET to send the information to the server.

Thank you for helping me.
I tried to use Ajax to transfer the variable to the PHP file but it did not work because I don’t know the name and the location of the php file. It is a blank application and the whole code is in the ‘onExecute’ Event.

it should be at

…/appname/appname.php

1 Like

Thank you, I solved the problem with your help.