• Resolved tdechangy

    (@tdechangy)


    When using the plugin on this live server, ELM uses the path of an other log file @ /var/www/site-name.com/log/error.log instead of /wp-content/elm-error-logs/php-errors.log.

    I thought that this code would help but nothing changed :

    // Don't show errors to site visitors.
      @ini_set('display_errors', 'Off');
        if ( !defined('WP_DEBUG_DISPLAY') ) {
        define('WP_DEBUG_DISPLAY', true); 	// false = only fatal errors
        }
    
    // Enable "Error Log Monitor" (plugin @ Dashboard).
      @ini_set('log_errors', 'On');
      @ini_set('error_log', '../wp-content/elm-error-logs/php-errors.log');

    Side effects :
    – I see many logs that I didn’t see on my localhost or other server installs. Not sur of what it means yet.
    – Clearing logs don’t work !

    What can be done please ?

    • This topic was modified 4 years, 2 months ago by tdechangy.
Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author Janis Elsts

    (@whiteshadow)

    Try setting erorr_log to an absolute (i.e. full) file path instead of a relative path. This plugin doesn’t fully support relative log file paths at the moment.

    Also, could it be that your hosting provider just doesn’t allow changing the log file location? If that’s the case, you probably won’t be able to move the log with any plugin.

    Finally, I don’t think it’s a good idea to enable WP_DEBUG_DISPLAY on a live site, even if you disable display_errors. As far as I know, you don’t actually need WP_DEBUG_DISPLAY to log non-fatal errors; you need WP_DEBUG.

    Thread Starter tdechangy

    (@tdechangy)

    I still wait the answer from the host but it’s probably an issue on their side as you mention.

    About the wp-config snippets, this one is in fact suggested when installing your own plugin, so what should be done ? Should you remove it from your suggestions too ?

    // Don't show errors to site visitors.
      @ini_set('display_errors', 'Off');
        if ( !defined('WP_DEBUG_DISPLAY') ) {
        define('WP_DEBUG_DISPLAY', true); 	// false = only fatal errors
        }
    Plugin Author Janis Elsts

    (@whiteshadow)

    The plugin does show a similar code snippet, but it’s not exactly the same:

    //Don't show errors to site visitors.
    @ini_set('display_errors', 'Off');
    if ( !defined('WP_DEBUG_DISPLAY') ) {
        define('WP_DEBUG_DISPLAY', false);
    }

    Could it be that the original snippet (above) got edited after it was copied to wp-config.php?

    Thread Starter tdechangy

    (@tdechangy)

    All right, it seems that the log file location can’t be moved as you said.

    Thanks.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Select Log file manually’ is closed to new replies.