• Hello.

    I have the same problem.

    Form sends default values.

    This code from previous topic is not working :

    $values = (array) $tag['values'];
    
        // Value
        if ( is_a( $wpcf7_contact_form, 'WPCF7_ContactForm' ) && $wpcf7_contact_form->is_posted() ) {
            if ( isset( $_POST['_wpcf7_mail_sent'] ) && $_POST['_wpcf7_mail_sent']['ok'] )
                $value = '';
            else
                $value = stripslashes_deep( $_POST[$name] );
        } else {
            $value = isset( $values[0] ) ? $values[0] : '';
        }
    
        if($_POST[$name] == $values[0]) $_POST[$name]= '';

    Help me pls!

    http://wordpress.org/extend/plugins/contact-form-7/

Viewing 2 replies - 1 through 2 (of 2 total)
  • It doesn’t work for me either…. Blast!

    It does work actually I was wrong. You must be doing the same thing I was. Just add it after the second $name = $tag[‘name’] there are 2 of those in modules/text.php worked perfectly. God Bless wordpress forums

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘[Plugin: Contact Form 7] Passing validation with default values’ is closed to new replies.