This topic is locked

How to determine Server Error

10/15/2025 09:28:36
PHPRunner General questions
A
asawyer13 authorDevClub member

I am getting a server error on some of my pages but when I click on the Show Details it doesn't show anything.
I have looking at Browser Console and no entries there at all.

What's the best way to debug the dreaded red Server Error?

Thanks
Alan

ChatGPT 10/15/2025

Hi Alan,

Debugging server errors in PHPRunner can be a bit tricky, especially if the error details are not being displayed. Here are some steps you can take to troubleshoot and identify the issue:

  1. Enable Error Reporting:

    • In your index.php file (or the main entry point of your application), you can enable error reporting to get more detailed error messages. Add the following lines at the top of the file:
      error_reporting(E_ALL);
      ini_set('display_errors', 1);



  2. Check Server Logs:

    • Look at your web server's error logs (e.g., Apache or Nginx) for any entries that correspond to the time of the error. This can often provide insights into what is going wrong.


  3. Review PHPRunner Settings:

    • Ensure that your database connection settings are correct. If there's an issue connecting to the database, it can result in server errors.
    • Make sure all required files and dependencies are present on the server.


  4. Test Environment:

    • If you are running on a local development environment, try switching to a different server setup (like XAMPP, WAMP, or MAMP) to see if the issue persists.


  5. Check for Syntax Errors:

    • Review your PHP code for any syntax errors or mistakes that could be causing the server error. You can use an IDE or a linter to help catch these issues.


  6. Disable Custom Code:

    • If you have added any custom code (like event handlers or custom SQL queries), temporarily disable them to see if they are causing the issue.


  7. Check Permissions:

    • Ensure that the permissions for your application files and folders are correctly set. Sometimes incorrect permissions can prevent the server from accessing the necessary files.


  8. Use Debug Mode in PHPRunner:

    • PHPRunner has a debug mode which can be enabled in the application's settings. This can provide additional information about the queries and actions being taken.


  9. Browser Developer Tools:

    • Even though you mentioned there are no entries in the console, sometimes the Network tab can show the response from the server. Look for the request that failed and see if there is more information in the response body.


  10. Consult PHPRunner Documentation and Forums:

    • If the issue persists, consult the PHPRunner documentation or visit forums (like the PHPRunner support forum) where other users may have faced similar issues.



By following these steps, you should be able to narrow down the source of the server error and resolve it. If you have specific error messages or behaviors, feel free to provide additional details for more targeted assistance.

Good luck with your debugging!

Best,
[Your Name]

Sergey Kornilov admin 10/15/2025

Start by posting a screenshot, it may provide some useful insight like where and when it happens etc.