Woocommerce Checkout Felder entfernen

Entfernen von Warenkorb Checkout Felder

/**
 * WooCommerce - Checkout-Felder entfernen
 */

add_filter( 'woocommerce_checkout_fields' , 'wp_bibel_de_remove_checkout_fields' );

function wp_bibel_de_remove_checkout_fields( $fields ) {
	unset($fields['billing']['billing_first_name']);
	unset($fields['billing']['billing_last_name']);
/*
	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_email']);
	unset($fields['billing']['billing_phone']);
*/	
	unset($fields['shipping']['shipping_first_name']);
	unset($fields['shipping']['shipping_last_name']);
/*
	unset($fields['shipping']['shipping_company']);
	unset($fields['shipping']['shipping_address_1']);
	unset($fields['shipping']['shipping_address_2']);
	unset($fields['shipping']['shipping_city']);
	unset($fields['shipping']['shipping_postcode']);
	unset($fields['shipping']['shipping_country']);
	unset($fields['shipping']['shipping_state']);
	
	unset($fields['account']['account_username']);
	unset($fields['account']['account_password']);
	unset($fields['account']['account_password-2']);
	
	unset($fields['order']['order_comments']);
*/

	return $fields;
}

Für alle snippets benutzen wir das Plugin code snippet.

Woocommerce Checkout Felder umbenennen

Umbenennen der Warenkorb Checkout Felder

/**
 * WooCommerce - Checkout-Felder umbenennen
 */

add_filter( 'woocommerce_checkout_fields' , 'wp_bibel_de_rename_checkout_fields' );

function wp_bibel_de_rename_checkout_fields( $fields ) {
	$fields['billing']['billing_company']['label'] = 'Name, Vorname oder Firma eingeben';
	$fields['billing']['billing_company']['placeholder'] = 'Name, Vorname oder Firma eingeben';

	return $fields;
}

Für alle snippets benutzen wir das Plugin code snippet.