• Resolved herowow

    (@herowow)


    $args = array(‘post_type’ => ‘wpcf7s’, ‘posts_per_page’ => 10);
    $cf7Forms = get_posts( $args );
    $post_ids = wp_list_pluck( $cf7Forms , ‘ID’ );
    $form_titles = wp_list_pluck( $cf7Forms , ‘post_title’ );
    $form_content = wp_list_pluck( $cf7Forms , ‘post_content’ );

    if ( have_posts() ) while( have_posts() ): the_post(); ?>
    <?php var_dump( $form_content); ?>

    <?php
    endwhile;
    wp_reset_query();
    ?>

    // the problem is, i want to loop through saved form the only thing i’m receiving is:

    This e-mail was sent from a contact form on TestPlug (https://192.168.1.33)”
    [0]=>
    string(149) “From: [your-name]
    Subject: [your-subject]

    Message Body:
    [your-message]

    • This topic was modified 7 years, 2 months ago by herowow.

    The page I need help with: [log in to see the link]

Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Is there a way to loop through submitted form via code’ is closed to new replies.