• Resolved Jamie Burchell

    (@jamieburchell)


    Hi

    We are seeing this error in our logs:

    require_once(/var/www/vhosts/project/releases/139/web/app/plugins/simple-event-planner/public/partials/single-event/ical.phpwp-load.php): failed to open stream: No such file or directory in /var/www/vhosts/project/releases/139/web/app/plugins/simple-event-planner/public/partials/single-event/ical.php on line 14

    Line 14, is this line:

    require_once( explode( "wp-content" , __FILE__ )[0] . "wp-load.php" );

    I believe the problem is that it is assumed incorrectly where the plugin will be. In a Roots Bedrock environment, the directory structure is different:

    https://docs.roots.io/bedrock/master/folder-structure/

    Overriding the template in my own theme and changing the require_once does not work – the same error is reported.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Hi @jamieburchell,

    We really appreciate your efforts thanks for pointing it out. We will fix the issue in the next release of the Simple Job Board plugin.

    Feel free to reach out for further assistance.

    Regards,

    Thread Starter Jamie Burchell

    (@jamieburchell)

    Thanks for the prompt reply. Just to note this is the “Simple Event Calendar” plugin.

    I was able to work around the issue by overriding both event-calendar.php and ical.php in my theme.

    In event-calendar.php I changed line 67 to:

    $iCal_file_path = get_stylesheet_directory_uri() . '/simple_event_planner/single-event/ical.php';

    Then in my overridden ical.php, line 14:

    require_once( __DIR__ . "/../../../../../wp/wp-load.php" );

    The path of course will be different depending on your environment. Not ideal, but it works. It might help someone.

    Cheers
    Jamie

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

The topic ‘PHP Fatal error: require_once(): Failed opening required ical.phpwp-load.php’ is closed to new replies.