Craig Ralston

Web Developer

Add New Fields to WooCommerce Checkout Form

Start by adding a new field to the billing checkout form

I end up with a new input field that looks like:

Now, we need to save the value of that field to the user_meta table, like so:

Now that data is stored in user_meta, we need to hook in to the profile area to display it and allow it to be edited by the user or admins.

I chose to break my additional fields into their own table just above the default Woocommerce fields as I have many of them and they are more specific to the user rather than the order processing itself, so I keep them organized in their own table titled “Additional Fields”.

Contact Form 7 – “Send me a copy” Checkbox

UPDATE: The following code no longer works as of CF7 v3.9 as the author has changed how wpcf7_before_send_mail() works. Here is an updated guide for v3.9+ written by Max Pohlenz

Contact Form 7 is a highly customizable and widely used WordPress plugin (at the time of writing there have been 24,137,767 downloads); We currently have 67 of our 98 WordPress sites with this plugin installed.

I recently had a client request a checkbox field for “Send me a copy of this message” which, when checked, should send the user their own copy of the form submission. This is not an entirely uncommon request and luckily, CF7 is pretty well-developed and allows developers to extend the plugin via filters.

The following shows the end result; a checkbox in which the user can choose to send a copy of the form to themselves as well as the set recipient:

Add that as either a plugin or in your child theme functions.php file.

Next, load up your form in the admin area.

Create your checkbox using [checkbox copymyself "Send me a copy of this message"] – It is important you use the same name as you checked for in the function above (in this case, “copymyself”) or this will not work.

IMPORTANT: Mail(2) needs to be turned on in CF7 settings area.

jStat – WordPress

jStat is a statistical library written in JavaScript that allows you to perform advanced statistical operations without the need of a dedicated statistical language ( i.e. MATLAB or R ). This plugin installs jStat and required jQuery plugins to your installation.

Still in very early development so JS skills are required to make use of this plugin.

Download

sketchJS – WordPress

Sketch.js is an easy-to-use jQuery plugin that allows you to create canvases upon which visitors can draw.

Still in very early development so JS skills are required to make use of this plugin.

Download