More Related Content
Similar to Customizing Your WooCommerce Store (20)
Customizing Your WooCommerce Store
- 9. Child Theme It
Extend the power of your theme
Override only that what s needed
Keep your theme updatable
This is where your custom CSS goes!
- 13. On wordpress.org
WooCommerce Product Archive Customiser
https://wordpress.org/plugins/woocommerce-product-archive-customiser/
WooCommerce Product Details Customiser
https://wordpress.org/plugins/woocommerce-product-details-customiser/
WooCommerce Customizer
https://wordpress.org/plugins/woocommerce-customizer/
- 18. Checkout fields
function dlm_checkout_fields( $fields ) {
unset( $fields['billing']['billing_phone'] );
unset( $fields['billing']['billing_address_2'] );
return $fields;
}
add_filter( 'woocommerce_checkout_fields',
‘dlm_checkout_fields’ );
- 19. No Order Notes Field
add_filter( 'woocommerce_enable_order_notes_field',
'__return_false' );
- 20. Change ATC Label
function wpm_change_adc_text( $text, $product ) {
return 'Yeah Buddy!';
}
add_filter( 'woocommerce_product_add_to_cart_text',
'wpm_change_adc_text', 10, 2 );
- 21. Personalize Thank You
function dlm_title_order_received( $title, $id ) {
if ( is_order_received_page() && get_the_ID() === $id ) {
global $wp;
$order_id = apply_filters( 'woocommerce_thankyou_order_id', absint( $wp-
>query_vars['order-received'] ) );
$order_key = apply_filters( 'woocommerce_thankyou_order_key', empty( $_GET['key'] ) ? ''
: wc_clean( $_GET['key'] ) );
if ( $order_id > 0 ) {
$order = wc_get_order( $order_id );
if ( $order->order_key != $order_key ) {
unset( $order );
}
}
if ( isset ( $order ) ) {
$title = sprintf( "Thank you, %s!", esc_html( $order->billing_first_name ) );
}
}
return $title;
}
add_filter( 'the_title', 'dlm_title_order_received', 10, 2 );
- 23. What Happens Next?
function dlm_what_happens_next() {
?>
<div class="dlm-what-happens-next">
<strong>What happens next?</strong>
<p>After you've completed your payment you'll receive an email
containing your license keys and a download links.</p>
</div>
<?php
}
add_action( 'woocommerce_after_checkout_form',
'dlm_what_happens_next' );
- 28. Product Short Description
<?php
global $post;
if ( ! $post->post_excerpt ) return;
?>
<div itemprop="description">
<?php echo apply_filters( 'woocommerce_short_description',
$post->post_excerpt ) ?>
</div>
single-product/short-description.php
- 29. Product Short Description
<?php
global $post;
if ( ! $post->post_excerpt ) return;
?>
<p itemprop="description">
<?php echo apply_filters( 'woocommerce_short_description',
$post->post_excerpt ) ?>
</p>
single-product/short-description.php