Help Desk

Help page blank

  • Posts: 7 Topics: 2
    | Permalink

    While troubleshooting a theme conflict, I just noticed the logging option on the Help page and set it to full. Now my entire Help page is blank.

    Posts: 2037 Topics: 1
    | Permalink

    Hi there,

    Thank you for reaching out to us! I’m sorry to hear that you are having problems with our logging: let me help you to solve this!

    Could you please add the following code to your theme’s functions.php file and let me know if it helps you to disable logging and solve the problem?

    # Disable logging
    add_filter( 'tribe_common_logging_engines', '__return_empty_array' );

    Thanks!

    Patricia

    Posts: 7 Topics: 2
    | Permalink

    Well, with that in functions.php, the help page loads and I was able to set logging to disabled. However, once I remove the code from functions.php, the help page still fails to render.

    Posts: 2037 Topics: 1
    | Permalink

    Hi there,

    I’m sorry to hear that!

    Could you please let me know if, while having WP_DEBUG enabled, do you get a PHP Fatal error like this one in your site?

    PHP Fatal error: Uncaught exception ‘UnexpectedValueException’ with message ‘DirectoryIterator::__construct(/tmp): failed to open dir: Permission denied’

    This error would mean that you don’t have access to the /tmp directory on your server: either the /tmp directory doesn’t exist (it usually resides in the root folder of your server), or you don’t have privileges to write to this directory. With privileges -755 you should be able to work with this folder.

    You can also set a custom directory for file logging. We have a tribe_file_logger_directory filter that you can utilize, it can be seen in action here:

    https://github.com/moderntribe/tribe-common/blob/4.6.2/src/Tribe/Log/File_Logger.php#L25

    You can customize the directory using that filter, just be sure to add an .htaccess file that restricts HTTP access to that directory so the logs aren’t visible to the public / search engines.

    I hope this helps! If you have any other questions please feel free to let me know and I’d be happy to help as best I can!

    Best Regards,

    Patricia

    Posts: 7 Topics: 2
    | Permalink

    No, I do not get any errors with or without.

    • This reply was modified 7 months, 2 weeks ago by  opendrives.
    Posts: 2037 Topics: 1
    | Permalink

    Hi there!

    That’s odd. Maybe the error is not showing up in your Dashboard while having only WP_DEBUG enabled. Could you please enable both WP_DEBUG and WP_DEBUG_LOG and share with us any messages you see while accessing your Help page? All WP_DEBUG messages will be stored in a debug.log file in /wp-content.

    This info would help us to identify the cause of the issue in your specific case.

    Thanks!

    Patricia

    Posts: 7 Topics: 2
    | Permalink

    Still nothing. Here’s what I added to functions.php and no debug.log file gets generated in /wp-content or anywhere else that I can find.

    # Disable logging
    add_filter( 'tribe_common_logging_engines', '__return_empty_array' );
    define( 'WP_DEBUG', true );
    define( 'WP_DEBUG_LOG', true );
    Posts: 2037 Topics: 1
    | Permalink

    Hi there,

    Could you please temporarily remove the “add_filter” line and access your Help page again? This filter is fixing the problem (disabling logging), that’s probably the reason why you didn’t get any errors while having WP_DEBUG and WP_DEBUG_LOG enabled yet.

    Thanks!

    Patricia

    Posts: 7 Topics: 2
    | Permalink

    Ok, just tried that. Same result. No error in the dashboard and no log file created.

    Posts: 2037 Topics: 1
    | Permalink

    Hi there,

    This sounds like a server limitation as you are unable to log and display PHP errors. I’ve just reviewed your system info and apparently you don’t have a value for PHP display_errors (it is currently blank):

    PHP
    display_errors =
    log_errors = 1

    At this point I would recommend you to contact your hosting provider and ask them to take a look at your php.ini file and make sure that you are actually able to display and log errors in your server. We won’t be able to help you with the next steps if we don’t know the error that is causing the problem.

    You also have the option to keep that filter enabled in your functions.php file: it will keep tribe_logging disabled and you will be able to access the Help page normally. I agree this is not the best solution but is the workaround we have at this moment.

    If you have any news regarding your error log or have any other questions in the meantime, please let me know!

    Posts: 7 Topics: 2
    | Permalink

    Ok, I enabled display_errors and this is what I got in the dashboard:

    Fatal error: Uncaught exception 'RuntimeException' with message 'SplFileInfo::isReadable(): open_basedir restriction in effect. File(/tmp/..) is not within the allowed path(s): (/var/www/vhosts/opendrives.com/:/tmp/)' in /var/www/vhosts/opendrives.com/wordpress.opendrives.com/wp-content/plugins/the-events-calendar/common/src/Tribe/Log/File_Logger.php:239 Stack trace: #0 /var/www/vhosts/opendrives.com/wordpress.opendrives.com/wp-content/plugins/the-events-calendar/common/src/Tribe/Log/File_Logger.php(239): SplFileInfo->isReadable() #1 /var/www/vhosts/opendrives.com/wordpress.opendrives.com/wp-content/plugins/the-events-calendar/common/src/Tribe/Log/Admin.php(129): Tribe__Log__File_Logger->list_available_logs() #2 /var/www/vhosts/opendrives.com/wordpress.opendrives.com/wp-content/plugins/the-events-calendar/common/src/Tribe/Log/Admin.php(16): Tribe__Log__Admin->get_available_logs() #3 /var/www/vhosts/opendrives.com/wordpress.opendrives.com/wp-content/plugins/the-events-calendar/common/src/admin-views/tribe-options-help.php( in /var/www/vhosts/opendrives.com/wordpress.opendrives.com/wp-content/plugins/the-events-calendar/common/src/Tribe/Log/File_Logger.php on line 239
    Posts: 2037 Topics: 1
    | Permalink
    Correct Answer

    Hi there,

    Thanks! Based on the error you just shared, I would recommend you to contact your hosting provider and ask them to modify the PHP open_basedir setting to none.

    After this change, please access your help page again and let me know how it goes!

    If you have any other questions in the meantime, please feel free to let me know and I’d be happy to help as best I can!

    Cheers,

    Patricia

    Posts: 7 Topics: 2
    | Permalink

    Got it. Changing open_basedir to none does resolve the help page load issue.

    Posts: 2037 Topics: 1
    | Permalink

    Hi there,

    I’m glad to hear that everything is working as expected now! If you need an assistance again or have other concerns, please feel free to open up a new thread, we’ll be more than happy to help you!

    Best Regards,

    Patricia

    | Permalink

The topic ‘Help page blank’ is closed to new replies.