Menu

Snippets

Yet another programmer blogging about code

Posts Tagged ‘woocommerce’

Customise WooCommerce out of stock message

Friday, December 23rd, 2016

Sometimes the WooCommerce out of stock message isn’t quite appropriate. Here’s a couple of ways to change that message. (more…)

Sort WooCommerce products first in search results

Thursday, December 18th, 2014

When shoppers search a WordPress website, you want them to find products first before listing any articles and pages. And it’s surprisingly easy to achieve, with a simple filter hook. (more…)

Order Form for WooCommerce

Sunday, April 27th, 2014

I have a new plugin, and it’s my first premium plugin (i.e. it’s not free!) — Order Form for WooCommerce. I’ve had it in the works since late last year when I wrote to meet some requirements for a client’s website, and it’s taken me until now (late April) to release it to the world at large. Please have a play with it on the demo site. US $25 US $40, cheap! :)

Remove SKU from WooCommerce front end

Friday, April 25th, 2014

If you need to have SKUs on products in WooCommerce, but don’t want to show them on the front end, you can’t just untick an option in the WooCommerce settings: you can either have and show SKUs or not have them at all. So here’s a quick snippet that lets you have them, but remove them from the front end. (more…)

WooCommerce quantity fields without spinners

Tuesday, November 12th, 2013

WooCommerce uses HTML5 number fields for shop quantities, because they restrict the characters you can enter, and Safari on iPad/iPhone conveniently shows the number keyboard. Webkit and Opera/Presto add spinners (up/down arrows) to HTML5 number fields. WooCommerce also adds +/- buttons surrounding qty fields, because IE and Firefox don’t add spinners. WooCommerce then uses CSS to hide the spinners on Webkit: (more…)

WooCommerce add to cart with quantity and AJAX

Sunday, August 18th, 2013

WooCommerce is a great e-commerce plugin for WordPress. It has some very nice basic features, but it’s also easy to customise and extend. On single product pages, you can add to cart with a quantity other than just one, and on the purchase page you can add to cart via AJAX without leaving the page. Wouldn’t it be nice to add to cart with both quantity and AJAX? (more…)

eWAY integrations for WooCommerce, Events Manager, Another WordPress Classifieds Plugin

Friday, March 1st, 2013

The eWAY Payment Gateway plugin now has integrations for WooCommerce, Events Manager Pro, and Another WordPress Classifieds Plugin with support for Australian customers of eWAY. And it’s still free! (more…)

Subscribe to mailing list in WooCommerce checkout

Monday, December 31st, 2012

A common requirement when building an online shop is to ask shoppers if they’d like to subscribe to shop’s newsletter, so that they can be updated when new products and specials are available. WooCommerce doesn’t come with such things as part of their standard checkout form, but with a few handy hooks, it’s very easy to add. (more…)

How to hack a WordPress plugin that doesn’t have the filters you want

Thursday, August 16th, 2012

The best thing about WordPress, besides the fact that nearly anyone can edit a website built with it, is hooks. Filter and action hooks allow developers like me to customise a WordPress website in myriad ways. Many good plugins provide hooks too. But inevitably, you’ll run up against a problem where you’d like a plugin to have a hook that it just doesn’t have. You can ask the plugin author nicely to add that hook, and maybe they’ll add it sometime soon, maybe even on time for your deadline. But what if your deadline comes before they add it? (more…)