• Resolved almendron

    (@almendron)


    WordPress 6.8.2
    PHP 8.3.22

    While attempting to clear the log:

    Warning: fopen(/furanet/sites/almendron.com/web/htdocs/logs/error_log): Failed to open stream: Permission denied in /furanet/sites/almendron.com/web/htdocs/tribuna/wp-content/plugins/error-log-monitor/Elm/PhpErrorLog.php on line 87

    Fatal error: Uncaught TypeError: fclose(): Argument #1 ($stream) must be of type resource, false given in /furanet/sites/almendron.com/web/htdocs/tribuna/wp-content/plugins/error-log-monitor/Elm/PhpErrorLog.php:88 Stack trace: #0 /furanet/sites/almendron.com/web/htdocs/tribuna/wp-content/plugins/error-log-monitor/Elm/PhpErrorLog.php(88): fclose(false) #1 /furanet/sites/almendron.com/web/htdocs/tribuna/wp-content/plugins/error-log-monitor/Elm/DashboardWidget.php(1333): Elm_PhpErrorLog->clear() #2 /furanet/sites/almendron.com/web/htdocs/tribuna/wp-includes/class-wp-hook.php(324): Elm_DashboardWidget->handleLogClearing('') #3 /furanet/sites/almendron.com/web/htdocs/tribuna/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters(NULL, Array) #4 /furanet/sites/almendron.com/web/htdocs/tribuna/wp-includes/plugin.php(517): WP_Hook->do_action(Array) #5 /furanet/sites/almendron.com/web/htdocs/tribuna/wp-admin/admin.php(176): do_action('admin_init') #6 /furanet/sites/almendron.com/web/htdocs/tribuna/wp-admin/index.php(10): require_once('/furanet/sites/...') #7 {main} thrown in /furanet/sites/almendron.com/web/htdocs/tribuna/wp-content/plugins/error-log-monitor/Elm/PhpErrorLog.php on line 88
    • This topic was modified 9 months ago by almendron.

    The page I need help with: [log in to see the link]

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author Janis Elsts

    (@whiteshadow)

    Thank you for the report. That error should be fixed in the next version.

    However, to actually clear the log, you might need to adjust the file permissions. It looks like the log file is not writable by PHP (which is unusual, but that’s what the warning seems to suggest).

    Thread Starter almendron

    (@almendron)

    I have verified that the ‘logs’ folder is a system folder. Its contents cannot be deleted or modified.

    Tip: The plugin checks whether it is possible to clean the registry. If the folder is not writable, it displays a warning (without causing a fatal error).

    Plugin Author Janis Elsts

    (@whiteshadow)

    Yes, the next version should display a custom error message in the widget instead of causing a fatal error.

    If the file can’t be modified by PHP, you may have to clear it yourself in this case.

    Thread Starter almendron

    (@almendron)

    Okay. Thank you very much.

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Fatal Error’ is closed to new replies.