WordPress.org

Ready to get started?Download WordPress

Forums

Easy Contact Forms
[resolved] How to fix Fatal error: require_once(): Failed opening required '.../easy-contac (2 posts)

  1. cwinkler78
    Member
    Posted 1 year ago #

    I wanted to post this solution, in case anyone else was having the same issue I was.

    I installed some WP Security plugins that renamed the default wp-content directory to make my site more secure. This caused the following error when accessing pages using my Easy Contact Form:

    Warning: require_once(/home2/YOUR-WEBSITE-NAME/public_html/wp-content/plugins/easy-contact-forms/easy-contact-forms-utils.php): failed to open stream: No such file or directory in /home2/YOUR-WEBSITE-NAME/public_html/NEW-PREFIX-content/plugins/easy-contact-forms/easy-contact-forms.php on line 275 Fatal error: require_once(): Failed opening required '/home2/YOUR-WEBSITE-NAME/public_html/wp-content/plugins/easy-contact-forms/easy-contact-forms-utils.php' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home2/YOUR-WEBSITE-NAME/public_html/NEW-PREFIX-content/plugins/easy-contact-forms/easy-contact-forms.php on line 275

    The plugin seems to know that the directory was renamed, but still can't find the file.

    In order to fix this, you will need to open the easy-contact-forms.php file in your favorite code editor. It will be located in your new directory, probably something like this:

    /home2/YOUR-WEBSITE-NAME/public_html/NEW-PREFIX-content/plugins/easy-contact-forms/easy-contact-forms.php

    Find the following lines:

    Line 107 DEFINE('_EASYCONTACTFORMS_DIR', 'wp-content/plugins/easy-contact-forms');
    Line 265 DEFINE('_EASYCONTACTFORMS_DIR', 'wp-content/plugins/easy-contact-forms');

    and change wp-content to your new directory name. Save your changes and your form should work again.

    http://wordpress.org/extend/plugins/easy-contact-forms/

  2. cwinkler78
    Member
    Posted 1 year ago #

    Marking as resolved.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic