• Hi, I see error reporting of your plugin.
    Hope you can give me a hint how to fix it.
    Can disable the call to include the file from line 154:
    $template_file = apply_filters( ‘mailtpl/customizer_template’, MAILTPL_PLUGIN_DIR . “/admin/templates/default.php”);
    I also don’t have a map like: content/themes/Avada-Child-Theme/admin/templates/
    Only have the map: content/themes/Avada-Child-Theme

    Warning: include_once(/home/deb96951n3/domains/website.com/public_html/wp-content/themes/Avada-Child-Theme/admin/templates/default.php): failed to open stream: No such file or directory in /home/deb96951n3/domains/website.com/public_html/wp-content/plugins/email-templates/includes/class-mailtpl-mailer.php on line 154 Warning: include_once(): Failed opening ‘/home/deb96951n3/domains/website.com/public_html/wp-content/themes/Avada-Child-Theme/admin/templates/default.php’ for inclusion (include_path=’.:/opt/alt/php72/usr/share/pear’) in /home/deb96951n3/domains/website.com/public_html/wp-content/plugins/email-templates/includes/class-mailtpl-mailer.php on line 154

    Regards,

    • This topic was modified 6 years, 7 months ago by RonaldS.
Viewing 3 replies - 1 through 3 (of 3 total)
  • Hi.

    When does happened it? when do you activate the plugin? Do you modified the plugin?

    Thanks

    Thread Starter RonaldS

    (@norus)

    I run a cron script everry night to inform me about an update that I do then.
    It runs already a year.
    When activating your plugin this week I get the error message.

    Here the script without credentials:
    if (!isset($_SERVER[‘HTTPS’]) || $_SERVER[‘HTTPS’] != ‘on’) {
    $full_url = ‘https://’.$_SERVER[‘HTTP_HOST’];
    } else {
    $full_url = ‘https://’.$_SERVER[‘HTTP_HOST’];
    }

    global $wpdb;
    date_default_timezone_set(‘Europe/Amsterdam’);
    $timestamp = time()+date(“Z”);

    // echo gmdate(“Y-m-d H:i”,$timestamp);

    mysqli_query($conn, “UPDATE wp_agent_adds SET date_added = CURDATE() WHERE user_id <= 1273 AND right(user_id, 1) in (1,3,7,9)” );

    $to = get_option(‘admin_email’);
    $subject = ‘cronjob: ‘.gmdate(“Y-m-d H:i”,$timestamp);
    $sender = get_option(‘admin_email’);
    $currentDomain = preg_replace(‘/www\./i’, ”, $_SERVER[‘SERVER_NAME’]);
    $headers = ‘FROM ME’;

    $mail = wp_mail( $to, $subject, ”, $headers );

    Hi.

    In the error we can see that MAILTPL_PLUGIN_DIR is not defined, then it takes empty value. As your script is located in “/home/deb96951n3/domains/website.com/public_html/wp-content/themes/Avada-Child-Theme/” then it show a error because the path “admin/templates/default.php” doesnt exists.

    Maybe your script need include “wp-blog-header.php” or better put your script in a function and call it with wp-admin/admin-ajax.php?action=script

    Regards

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘failed to open stream: No such file or directory’ is closed to new replies.