• Here is a patch I would like you to include. It would fix an error that is caused when you include wp-load.php from an external source other than a page view. It is just to add the line

    global $wpcf7_shortcode_manager;

    in contact-form-7/includes/shortcodes.php before the line

    $wpcf7_shortcode_manager = new WPCF7_ShortcodeManager();

    Here is a relevant forum post that had exactly this problem:

    https://www.ads-software.com/support/topic/plugin-contact-form-7-cf7-shortcode-error?replies=5

    and here is the .diff file:

    Index: trunk/includes/shortcodes.php
    =======================================
    — trunk/includes/shortcodes.php (revision 556777)
    +++ trunk/includes/shortcodes.php (working copy)
    @@ -166,6 +166,8 @@

    }

    +global $wpcf7_shortcode_manager;
    +
    $wpcf7_shortcode_manager = new WPCF7_ShortcodeManager();

    function wpcf7_add_shortcode( $tag, $func, $has_name = false ) {

    https://www.ads-software.com/extend/plugins/contact-form-7/

Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘[Plugin: Contact Form 7] Pull Request’ is closed to new replies.