Custom WordPress and WooCommerce Development

Tag: tutorial

  • Add Custom Fields to WordPress Menu Items

    First a little backstory A WordPress commit that I am personally very excited to finally see get merged into core is the addition of a wp_nav_menu_item_custom_fields hook! As the author of the Nav Menu Roles plugin, I’ve needed to display custom fields on menu items. But in the admin, the menu items are displayed by…

  • How to Add a Customizable Field to a WooCommerce Product

    UPDATED 9/29/2019: Noticed some code typos and updated some of the display sections for compatibility with WooCommmerce 3.7. In this WooCommerce tutorial I will be showing you how to add a custom field to the front-end of a WooCommerce product. We’ll be adding a text input that a customer could use to enter some special…

  • Create WooCommerce Multicheck Form Field

    I’ve expanded on the code I posted in my tutorial on how to customize the WooCommerce Checkout. First you need to register the new checkout fields. This is where I’ve added a current_user_can() to test if the current user has the appropriate capabilities to see these extra fields. I’m using the manage_options capability because it…

  • WooCommerce Customize Checkout Fields

    Note: This was updated for compatibility with WooCommerce 3.0+. This will cause fatal errors if used with older versions of WooCommerce. I was digging around in WooCommerce while trying to come up with a quote for a client. Part of the scope had me wondering if you could remove some fields from the checkout process.…

  • Add a Repeating Text Field to Options Framework Plugin

    Add a Repeating Text Field to Options Framework Plugin

    I don’t hardly even know why I was working on this today.  Well a friend wanted to be able to control the radio buttons in a metabox, from the backend (since the otherwise brilliant WP-Alchemy is all dev-level coding) and for some reason  my brain went to theme option.  He ultimately went a different route…

  • WordPress Filters Fundamentals

    Ok, so you’ve read my previous articles on PHP basics and how to use WordPress action hooks. Now you want to play with the big boys and girls and try your hand at filters. Just a reminder that you are still essentially learning a new language. Be patient with yourself. It took me close to…

  • How to Use Multiple WYSIWYG (TinyMCE) Visual Editors in Your WordPress Metaboxes

    Ever since WordPress invented the metabox, people have been trying to put the rich text editor (in WP this is provided by TinyMCE) into their metaboxes. And it makes sense. Sure us uber-geeks know the HTML tags required to make some text bold, but most of the world does not. But they do know how…

  • Create an Alphabetical Glossary of Posts in WordPress

    Once up a time i did a client project where i had to have archives organized alphabetically.   I ended up accomplishing by adding a query variable and targeting the posts_where filter.  However, in answering a recent question at WordPress Stack Exchange I decided that it might be neater to create a hidden taxonomy instead.  I…

  • Customizing the WordPress Install Process with install.php

    I came across a super interesting post at WPBits about [automating the wordpress installation][1] process.  Some of the parts about where some of the functions are located in WP that allow you to change certain things on the installation are outdated since the post is from 2007, but the concept remains perfectly intact.  If you find…

  • How to Find any Facebook ID

    Sometimes when using WordPress plugins you sometimes need to provide a facebook ID number. If the facebook URL you are looking at is using a username instead of an ID number it isn’t inherently obvious how to find that profile’s ID number.  You can go into a photo album and it might appear as part…