This topic is locked
[SOLVED]

 sending Error Message via email

6/19/2019 2:36:24 PM
PHPRunner General questions
K
keithh0427 author

In the PHPRunner manual there is a section on "Displaying server errors in AJAX mode".
To activate this, it indicates to use "Return 1/0" from the BeforeEdit function for example.
Is there a way to capture the text of the message and send it directly to a help desk via email?

admin 6/20/2019

We do not have a built-in option for this but you can check

function runner_error_handler($errno, $errstr, $errfile, $errline)



in include\phpfunctions.php file. This is where we process and display the error message.

K
keithh0427 author 6/20/2019



We do not have a built-in option for this but you can check

function runner_error_handler($errno, $errstr, $errfile, $errline)



in include\phpfunctions.php file. This is where we process and display the error message.


Thanks. I looked at that, but it would require a change to the function each time that PHPRunner was updated.
I also considered moving error.htm to error.php, but the same issue.

admin 6/28/2019

You can make your changes in PHPRunner's source code i.e. in C:\Program Files (x86)\PHPRunner10.2\source folder.

K
keithh0427 author 7/2/2019

I have created a function in the source folder to send the error message to the support team for my project.
However, I cannot see a way to call that function ourside of editing phpfunctions.php or appsettings.php or dbcommon.php, all of which would require editing with each new release of the PHPRunner code.
Have I missed something?

admin 7/3/2019

I guess you meant to say "I created a file in source folder". If my understanding is correct you can use this article to utilize your PHP file:

https://xlinesoft.com/phprunner/docs/how_to_add_external_files.htm

K
keithh0427 author 7/3/2019



I guess you meant to say "I created a file in source folder". If my understanding is correct you can use this article to utilize your PHP file:

https://xlinesoft.com/phprunner/docs/how_to_add_external_files.htm


Yes. Sorry. I created a .php file with the function in it and placed it inside the source folder.