Support » Plugin: Registrations for WooCommerce » Notice that enrollee name/email not listed

  • Resolved chenryahts

    (@chenryahts)


    After checkout, I see two alerts:

    Please enter a correct name to participant #1
    Please enter a correct email to participant #1

    Even after having added an enrollee name and email on the checkout page.

    I looked at the Github code, and wouldn’t these lines be if (empty... instead of if ( !empty...

    in class-wc-registrations-checkout.php, lines 119-127:

    				for( $i = 1; $i <= $qty; $i++, $registrations++ ) {
    					// Check if field is set, if it's not set add an error.
    					if ( ! empty( $_POST['participant_name_' . $registrations] ) ) {
    						wc_add_notice( sprintf( __( 'Please enter a correct name to participant #%u ', 'registrations-for-woocommerce' ), $registrations ) );
    					}
    					if ( ! empty( $_POST['participant_email_' . $registrations ] ) ) {
    						wc_add_notice( sprintf( __( 'Please enter a correct email to participant #%u ', 'registrations-for-woocommerce' ), $registrations ) );
    					}

    It is adding the first name and email address to the Woocommerce Order in the orders screen.

Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Notice that enrollee name/email not listed’ is closed to new replies.