Woocommerce Removing "Additional information" Name On Checkout Page

In my Wordpress Woocommerce site I have removed all of the shipping and billing details so the customer only has to enter their first, last and email. I'm selling vertical products, I don't want or need all those details. What I'm still seeing is Additional Information name is still showing up.

Your Information

First Name *

Last Name *

Email Address *

Confirm Email Address *

Additional Information

When I look at the html from the page I see:

</p></div>
</p></div>
<div class="col-2">
<div class="woocommerce-shipping-fields">
<h3>Additional Information</h3>
</p></div>  
</p></div>
</p></div>

It's some how plugged in so I can't just delete it. If I can please give insight how to find what file it might be in.

This is the code I've included in my child theme to remove all billing and shipping info:

// Hook in
add_filter( 'woocommerce_checkout_fields' , 'custom_override_checkout_fields' );

// Our hooked in function - $fields is passed via the filter!
function custom_override_checkout_fields( $fields ) {
unset($fields['order']['order_comments']);
unset($fields['billing']['billing_company']);
unset($fields['billing']['billing_address_1']);
unset($fields['billing']['billing_address_2']);
unset($fields['billing']['billing_city']);
unset($fields['billing']['billing_postcode']);
unset($fields['billing']['billing_country']);
unset($fields['billing']['billing_state']);
unset($fields['billing']['billing_phone']);

return $fields;
}

Thanks in advance for helpful advice

Answers


try to add this to your functions.php

add_filter('woocommerce_enable_order_notes_field', '__return_false');

The Additional Information title is located in file:

wp-content/plugins/woocommerce/templates/checkout/form-shipping.php

However i recommend you to create a child theme and make your customizations there. Adding the filter that @qutek recommends also works.

If you want to get rid of the 2 columns style that the checkout comes with, you should customize the div with the "customer_details" id located in file:

wp-content/plugins/woocommerce/templates/checkout/form-checkout.php

Need Your Help

How to get a dimension (slice) from a multidimensional array

c# .net arrays multidimensional-array jagged-arrays

I'm trying to figure out how to get a single dimension from a multidimensional array (for the sake of argument, let's say it's 2D), I have a multidimensional array: