Ok the problem was with using ‘year’ as the argument name, if I changed it to something else such as ‘y’ it seems to work.
Related Posts:
- WP_Query() show posts that end later than today
- exclude custom post type by meta key in wp_query
- Displaying custom posts only if custom meta box’s date is not expired
- Two near-identical custom field types – one works, the other doesn’t . What can cause this?
- Meta Query posts not showing on ending date of custom field
- Using WP meta query to show custom post types by a start and finish date
- How to sort WP_Query by a custom text field (written as a date dd/mm/yyyy)
- ACF meta_key and meta_value break loop
- Sort loop by custom field from different post type
- Loop posts in a table ordered by a custom field value
- How to get past and upcoming post by defining date in custom field?
- loop through custom post-type with two meta_keys
- Order Wp Query by earliest of 3 dates meta query
- WP_Query() displaying past post / event
- Post ID randomly printing on page
- A custom post within a custom post
- Display Custom Taxonomy Alphabetically
- Full Custom Post Type List Organised by two Taxonomies
- Displaying Custom Posts on a Page
- Shortcode not working with post counter
- Problem: wp_query outputs all images on site
- search suggest – filter post type
- Get custom post type’s fields in a while loop as variables
- Custom Post Type within the Loop on Homepage (Page Template)
- The loop seems stuck to a single (now deleted) post
- Posts per row on archive page (custom post type)
- How do I know the ‘meta_key’ for ordering my custom post type
- Admin Custom Meta Box – Pull Last 5 Posts from Custom Post Type
- Use the same date-based permalink structure for all post types
- Custom Theme With Custom Loops
- Configuring a meta query with multiple post types that have the same relationship on a single page
- Custom Post Types strange pagination problem
- Ordering custom post type by multiple custom fields
- How to Output which matched meta_keys were found from custom_type_posts?
- Possible to filter custom post type with multiple meta data?
- How to order posts of a custom post type by date DESC in dashboard Admin?
- Order post by date with ACF
- Custom post type conditional in loop
- Listing all term items alphabetically / sorting loop
- Display related custom taxonomy posts in sidebar
- filter search custom field query
- How to let users choose where to search for posts?
- pagination not working for category.php (custom post types in categories)
- Query based on custom fields start and end date
- Only show posts with date of today or in the future (i.e don’t show past posts)?
- How do I control the output of a custom post type in the loop?
- Display custom post type posts first, then default posts
- Custom Post Type Category Link
- Custom Post type category pages template and loop
- Three Most Recent Posts, One Per Term
- Targeting custom post type
- Does WP have a global of $id?
- WordPress Loop if/else
- get_the_title() is returning results from previous loop
- Custom Post Loop pulling all custom posts, not just one
- Conditional for a Single Post That Belongs to a Category?
- Wrapping x posts in html without leaving empty html
- WP Query post__in not returning correct results
- Custom Post Type single.php template only shows the latest post
- Sort posts in loop by the WooCommerce Membership of the author
- Including all post id’s of a custom post type into an array
- How to include custom post type posts on a page?
- 4 column-loop ordered alphabetically with entries grouped (and labeled) by their first letter
- Tag page only display 10 posts
- How can I group posts by months and years?
- Pagination Error : Duplicate argument being outputted
- get_post_type is always post
- Multiple Custom Post Type queries, how to DRY it up
- Custon Content within WordPress Loop
- Trying to Create a PHP Variable for post_type that can be referenced Site Wide
- Bootstrap accordion looping through posts incorrectly
- Main query not querying any posts in custom taxonomy template
- Loop increase number
- Custom post type showing same Post on all Pages
- get_post_meta is not working inside shortcode
- Using wp_query to modify the loop in index.php for a CPT
- the_post() is printing titles in page footer
- Custom WP_Query doesn’t display all posts
- Query & the_content() is showing in the header
- WP_query – Filter by tax_query and meta_query using multiple select
- Create Array from custom post type to display a slider
- Is it possible to load a different sidebar in single.php based on a meta_query filter?
- Move Genesis Single Page/Single Post Title
- get parent content inside child posts
- 3 random images from custom post type, each in a div with a diffrent class
- Two column layout with alphabetical ordering
- Post loop count is not in order
- Control content before and after custom post type loop
- Listing custom post types on archive page with array
- get_pagination not working on a custom post type query (using WP_Query)
- How to Make infinite loop of post
- WP_Query with custom post type ID
- Getting a custom post’s custom field based on another custom post’s custom field select
- Querying multiple values from a single key
- Displaying multiple post types on home page
- looping though custom post types and only return results in a given taxonomy
- Shortcode leaves no space for other elements?
- How to conditionally add Custom Post Type to Front Page
- Dynamically insert code to custom post type loop
- hide specific div on single.php [closed]