• I found closed support questions related to this, so wanted to add the solution. If you want to display contact form 7 forms in an admin page (eg via do_shortcode), then you will need a plugin like the one that follows enabled. It must be a plugin because it needs to happen before the plugins_loaded action.

    Cheers, and hope this helps someone,
    Russ Tyndall

    <?php
    /*
    Plugin Name: Contact Form 7 On Admin Screens
    Plugin URI: https://contactform7.com/
    Description: A tiny plugin to make Contact Form 7 work on admin
    Author: Russ Tyndall
    Author URI: https://www.acceleration.net/
    Text Domain: contact-form-7
    Version: 1
    
    */
    
    function sun_wpcf7_admin (){
      require_once WPCF7_PLUGIN_DIR . '/includes/controller.php';
    };
    add_action('plugins_loaded', 'sun_wpcf7_admin',1);

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

Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Using contact-form-7 from admin’ is closed to new replies.