Custom options for a Custom post type

The easiest solution will be using Advanced Custom Fields plugin, I guess. You can easily add custom write panels with it and limit them only for some posts based on post type, template file, etc. If you’d like to do implement it yourself, then you’ll have to add your custom meta box using add_meta_box function.

WordPress ERD mistake?

I found the reason: term_id is the ID of a term in the terms table. term_taxonomy_id is a unique ID for the term + taxonomy pair. see: What’s the difference between term_id and term_taxonomy_id Still, I think it’s a bit strange to do it this way. Also because I think it doesn´t make sence to … Read more

Can’t pull metadata for a term in my theme’s function.php

woocommerce_add_to_cart_validation is a filter that is run in the add_to_cart_action method of the WC_Form_Handler class. This method is attached to the init hook. add_action( ‘init’, array( $this, ‘add_to_cart_action’ ) ); Your taxonomy is quite probably also registered at the init hook. The WooCommerce action has no priority set, so the default would be 10. I … Read more

Page full of widgets?

Evidently this is not as much of a mystery as I first thought. Here’s 2 links. http://www.wpbeginner.com/plugins/how-to-add-wordpress-widgets-in-post-and-page-content/ http://wordpress.org/plugins/widgets-on-pages/

How to fix pagination for custom loops?

The Problem By default, in any given context, WordPress uses the main query to determine pagination. The main query object is stored in the $wp_query global, which is also used to output the main query loop: if ( have_posts() ) : while ( have_posts() ) : the_post(); When you use a custom query, you create … Read more