• Just wanted to thank the author for making this useful plugin. It’s stressful when a client wants something last minute and you know you might have to develop it yourself and do a bunch of testing.

    Thanks to this plugin I didn’t have to. Also the snippet to re-order the fields worked out perfectly and better yet added to a child theme instead of overriding a core file.

    If this helps, here’s how to get the e-mail verification field right under the regular e-mail field (add to functions.php, for me I did it in my child theme):

    //RE-ORDER BILLING FIELDS WITH EMAIL VALIDATION
    add_filter("woocommerce_checkout_fields", "order_fields");
    
    function order_fields($fields) {
    
        $order = array(
            "billing_first_name",
            "billing_last_name",
            "billing_company",
            "billing_address_1",
            "billing_address_2",
    	"billing_city",
            "billing_state",
            "billing_postcode",
            "billing_country",
            "billing_email",
    	"billing_email-2",
            "billing_phone"
    
        );
        foreach($order as $field)
        {
            $ordered_fields[$field] = $fields["billing"][$field];
        }
    
        $fields["billing"] = $ordered_fields;
        return $fields;
    
    }
Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Thanks for making a useful plugin! – Full Snippet for Reordering Fields’ is closed to new replies.