Woo | Developer Blog
  • Get started
  • Stay updated
    • Roadmap Insights
    • Changelog
    • Release downloads
    • Newsletter
    • WooCommerce Meetups
    • Join the Community Slack
  • Grow with Woo
    • Become a Woo agency partner
    • Become a Marketplace partner
    • Contribute to WooCommerce
  • Docs

General Snippets

  • Hide trailing zeros on prices

    Hide trailing zeros on prices

    Automattic Avatar
    Automattic

    |

    Sep 25, 2018


    The option to show trailing zeros on your prices has been removed in favor of a filter, as of WooCommerce 2.2x. If you want to hide trailing zeros on your… Read more

  • Notify Admin When New Account Is Created

    Notify Admin When New Account Is Created

    Automattic Avatar
    Automattic

    |

    Mar 11, 2018


    Add this code to your child theme’s functions.php file or via a plugin that allows custom functions to be added, such as the Code snippets plugin. Avoid adding custom code… Read more

  • Display product weight on archive pages

    Display product weight on archive pages

    Automattic Avatar
    Automattic

    |

    May 10, 2017


    To display WooCommerce product weight on archive pages, below the title of the product, add this code to your child theme’s functions.php file or via a plugin that allows custom functions to… Read more

  • Allowing customer access to WP Admin, and enabling the admin bar

    Allowing customer access to WP Admin, and enabling the admin bar

    Automattic Avatar
    Automattic

    |

    Mar 24, 2016


    Add code to your child theme’s functions.php file or via a plugin that allows custom functions to be added, such as the Code snippets plugin. Avoid adding custom code directly… Read more

  • Add a new country to countries list

    Add a new country to countries list

    Automattic Avatar
    Automattic

    |

    Aug 12, 2013


    Add this code to your child theme’s functions.php file or via a plugin that allows custom functions to be added, such as the Code snippets plugin. Please don’t add custom… Read more

  • Adjust the quantity input values

    Adjust the quantity input values

    Automattic Avatar
    Automattic

    |

    Jul 23, 2013


    Add code to your child theme’s functions.php file or via a plugin that allows custom functions to be added, such as the Code snippets plugin. Avoid adding custom code directly… Read more

  • Send coupons used in an order by email

    Send coupons used in an order by email

    Automattic Avatar
    Automattic

    |

    Jul 10, 2013


    This snippet sends by email the list of coupons used in an order. You can customize the “$to” variable and define your own email address, and the “$message” to have… Read more

  • Configuring Zeus Server Rewrite Rules

    Configuring Zeus Server Rewrite Rules

    Automattic Avatar
    Automattic

    |

    Jun 10, 2013


    This rewrite.script has been configured for WordPress: RULE_0_START: # get the document root map path into SCRATCH:DOCROOT from / # initialize our variables set SCRATCH:ORIG_URL = %{URL} set SCRATCH:REQUEST_URI =… Read more

  • Minimum Order Amount

    Minimum Order Amount

    Automattic Avatar
    Automattic

    |

    May 24, 2013


    Add code to your child theme’s functions.php file or via a plugin that allows custom functions to be added, such as the Code snippets plugin. Avoid adding custom code directly… Read more

  • Change a currency symbol

    Change a currency symbol

    Automattic Avatar
    Automattic

    |

    May 9, 2013


    See currency list for reference on currency codes. Add code to your child theme’s functions.php file or via a plugin that allows custom functions to be added, such as the… Read more

  • Rename a country in WooCommerce

    Rename a country in WooCommerce

    Automattic Avatar
    Automattic

    |

    Mar 17, 2013


    Add this code to your child theme’s functions.php file or via a plugin that allows custom functions to be added, such as the Code snippets plugin. Avoid adding custom code… Read more

  • Hide other shipping methods when “Free Shipping” is available

    Hide other shipping methods when “Free Shipping” is available

    Automattic Avatar
    Automattic

    |

    Sep 16, 2012


    Overview By default, WooCommerce will show all shipping methods that match the customer and the cart contents. This means Free Shipping will also show along with Flat Rate and other… Read more

Next Page→

Updates

  • Changelog
  • Release Packages
  • Release Calendar
  • Newsletter
  • Status

Information

  • About
  • Contact Us

Community

  • Community Slack
  • WooCommerce Meetups
  • GitHub Discussions
  • Community Forum
  • Code of Conduct
  • Community Participation Guide

Grow with Woo

  • Become a Woo agency partner
  • Become a Marketplace partner
  • Contribute to WooCommerce

Never miss an update

This field is hidden when viewing the form
This field is hidden when viewing the form
This field is hidden when viewing the form

Automattic Company Site

COPYRIGHT WOOCOMMERCE 2026
TERMS & CONDITIONS  PRIVACY POLICY  PRIVACY NOTICE FOR CALIFORNIA USERS
Do not sell or share my personal information.