Set up the object for the taxonomy term: Then you can use the object like this: Here’s everything available in the object:
Search the Wiki
z-index & fixed position
A great article/blog post: http://www.fiveminuteargument.com/fixed-position-z-index The two fixed-position divs on this page are marked up as: and styled thus: Note that the lower, orange element has a z-index specified, whilst the first element doesn’t. The ul just below this text has a relative position. When the page is scrolled, and the orange div overlaps that list, all looks fine. When the green div overlaps Full Article…
Nested loops with WP_Query
I struggled with this for a while and then realised the post object of the current query needs to be saved to a temporary variable [$save_original_post_object = $post;] so it can be restored after the nested loop is finished [$post = $save_original_post_object;]. Additionally you need to setup a new post object in the nested loop Full Article…
Building conditional WP_Query args based on variables
I have not seen this documented anywhere other than this thread I found on the WordPress Stackexchange: http://wordpress.stackexchange.com/questions/107471/how-to-use-tax-query-to-apply-both-terms-or-one-if-one-is-empty?codekitCB=403616342.846423 The following is my implementation of it on the NN Occ Health Job Matrix theme in the file ‘content/.php: ($body_demand_one, $body_demand_two are variables set from query parameters passed from the url.)
Delete WooCommerce comments type ‘Order Notes’
Run the following query on the database in PHPMyAdmin: