![]() |
bobdutil 11/15/2017 |
Hello, I'm new to phprunner and despite a lot of searching cannot see how to enter data automatically to a phprunner MySQL database (from a php script). I receive data from an app (http POST request) to a php script and need to send the resulting array to phprunner and trigger an 'Add' event or similar to save it in a new record. Can anyone help me please! Thanks in advance.
|
![]() |
Admin 11/15/2017 |
I think you can have better luck handling all this in your own script. Passing data to PHPRunner and executing events is somewhat complicated. You can probably execute the same event code in your own script. You can place event code into some external PHP file and include this file in both PHPRunner and your own PHP script. |
C
|
cjs99 author 11/17/2017 |
If I understand you correctly, you wouldn't need to do this in phpRunner. I would have the script call a stored procedure in your MySql database to insert the records into your table. Google "calling mysql stored procedure using php script". |
C
|
cjs99 author 11/17/2017 |
Thanks for your suggestions. I will try the stored procedure approach first and will let you know how I get on. |
C
|
cjs99 author 12/4/2017 |
Thanks for your suggestions. I will try the stored procedure approach first and will let you know how I get on.
|
C
|
cjs99 author 12/6/2017 |
I think you can have better luck handling all this in your own script. Passing data to PHPRunner and executing events is somewhat complicated. You can probably execute the same event code in your own script. You can place event code into some external PHP file and include this file in both PHPRunner and your own PHP script.
|
![]() |
Admin 12/6/2017 |
Just send that email from the same external script that inserts data. It is just not clear why do you need PHPRunner here. |