Support » Plugin: Contact Form 7 » Fix for WPML integration

  • Hi,

    This is David from the WPML compatibility team. We are trying to use the ‘wpcf7_admin_misc_pub_section’ action to add language controls to the form editor.

    In my tests it is working very well when we edit an existing form, but it’s not working properly when the form has just been created.

    Edit existing form URL:

    Newly added form URL:

    The newly added form is missing ‘action=edit’ in the URL and this is causing issues with WPML’s language metabox.

    I’d like to suggest the following change to fix this:

    diff --git a/admin/admin.php b/admin/admin.php
    index 4f3c2d9..a3aa76d 100644
    --- a/admin/admin.php
    +++ b/admin/admin.php
    @@ -233,6 +233,7 @@ function wpcf7_load_contact_form_admin() {
                    $query = array(
                            'post' => $contact_form ? $contact_form->id() : 0,
    +                       'action' => 'edit',
                            'active-tab' => isset( $_POST['active-tab'] )
                                    ? (int) $_POST['active-tab'] : 0,

    Would you accept such a change to give our shared users a better experience?
    Let me know what you think


    David GarcĂ­a Watkins
    WPML Compatibility Team
    The makers of WPML, Toolset and ICanLocalize

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Takayuki Miyoshi


    David, this is a volunteer-based public support forum for WordPress, and posting about commercial products like your WPML is prohibited here.

    I won’t modify my code just for the reason that it is convenient for a particular plugin, especially when it is a commercial one. Please resolve it on your side.

    I believe the fix is a generic one, not just for WPML.
    Anyone hooking on that filter will have the same issue.

    But we will handle it on our side anyway, no problem.

    Thanks for your reply.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Fix for WPML integration’ is closed to new replies.