The problem here is that, most probably, you store date in CF show_date
in ‘YYYY-mm-dd’ format.
You have to use the same format in comparisons…
Something like this should work just fine:
$args = array(
'post_type' => 'esitykset',
'meta_key' => 'show_date',
'orderby' => 'meta_value',
'order' => 'ASC',
'meta_compare' =>'>=',
'meta_value' => date('Y-m-d'),
'posts_per_page' => 20,
'paged' => get_query_var('paged')
);
Related Posts:
- Make Two Views of Post Type Archive At Two URLs
- How to remove current year from wp_get_archives
- Archive template
- Archive list for custom post type categories
- Check if is post type archive and in category
- Not able to see CPT archive template
- Create Archive Page with Visual Composer
- Add archive/category results to single post page
- Not able to see archive page of custom posts
- Archive Custom Post Type
- Custom Post Type archive (archive-{post-type}.php) is not working
- How to display archive page posts based on author_id
- Limiting the Archive page to posts posted by particular author
- Using WP_Query how can I show events (a custom post type) that are in the future?
- Archive-Custom-Post-Type order by Event Date, ASC, and hide events that have completed
- What code do I “comment out” to remove the loop from this Custom Taxonomy
- Group Archive list by posts tag
- Custom Post Archive – display page 1 differently then subsequent pages
- CountUp timer for custom post
- Custom Post Type Archive – archive.php is present, but it is not being used
- Custom post type archive url when post type has archive string
- get custom post archieve by month
- Customing Annual Archive plugin
- Notice- undefined variable post and trying to get property of non-object
- WordPress Rewrite Url with arugments
- How to link to an archive-special.php from a custom front-page template?
- Custom Post Type Archives by Year & Month?
- Get custom post type slug for an archive page
- Custom Post Type Settings page, choose page to display archive
- Adding a menu item for a Custom Post Archive
- Adding custom post type archives to a WordPress menu
- How do you create an archive for a custom post type from a plugin?
- Custom Post Type Archives by Date with Custom Permalink
- How to seamlessly redirect between different archive and singular slugs?
- Change title in head on Archive page
- Change number of posts to show on Archive page (custom post type)
- Custom Post Type archive as front page
- Adding custom post types to archive.php
- Update Old Links To Pretty Permalinks Custom Post Type
- archive-{$post_type}.php not loading. instead the default archive.php loads
- Create Custom Post Type Archive Page with Sub Categories Navigation Sidebar
- “Sticky” posts for each category (archive.php)
- How do I get WordPress URL rewrites into Sitemap?
- Custom Post Type archive link in WYSIWYG editor
- Archive page for custom post type not working
- Editable content on a Custom Archive page
- Tell wordpress to show a single page instead of an archive
- An empty Custom Post Type Archive page returns 404 in WP 3.1
- Custom Taxonomy template is not recognised
- is_main_query() not working for WP REST API
- Set up Custom-Post-Type Author Archive
- get the custom post type title/name
- Custom post type templating problem
- Custom Taxonomy Template Error: Catchable fatal error: Object of class WP_Error could not be converted to string
- Displaying Page as Custom Post type landing Page
- How do I exclude posts from custom taxonomy from a custom post type archive?
- CPT UI – elementor tags archive template not working
- Automatically Give All Custom Post Types a Pre-Set Category [duplicate]
- CPT archive admin menu label
- Creating a Custom Post Type
- Custom Post Type slug same as page name
- Content Editable CPT Archive?
- Custom post type archive pagination query issue
- Paginate_links in custom post type template
- Limit the Title Length on Custom Post Type Archive Page to a Set Number of Characters
- How to hyperlink content from archive page with custom post-type
- How to set up Custom Post Type archive page as Front page
- Get posts from a top category and group by child categories
- Polylang : Display term archive even if no posts
- Custom Permalinks For CPT and pages with parent. Advanced WordPress
- ACF for custom post type archive pages: which hook to use?
- How to display the_archive_title() and the_archive_description() – “weird” interaction
- CPT Archive pre_get_posts not working?
- Plain links in single-class.php and archive-class.php not working
- latest posts-widget displays all posts on archive page but works great anywhere else
- Make Next and Previous on single-$posttype.php use the same order as archive-$posttype.php
- CPT archive page – show one post from each taxonomy term
- Need equivalent of single_term_slug
- Specifying a template for custom post type pages
- 2 Custom Post Types In 1 Archive Page?
- Main query disturb pre_get_post by category query
- Different number posts per page based on custom post type term id
- Displaying all posts by category and showing content on click
- Redirect logged in users from a custom post type archive page if they don’t have a specific role
- I want to create a custom taxonomy page showing a list of subcategories
- Tell wordpress to show a single page instead of an archive page
- Custom post pagination not working
- Custom post type post_type_link gives “page not found” on any other custom post type
- Custom Post Type shows pagination (w/404) or posts_per_page query, but not both
- Rewriting archive page slug to be different than custom post type slug
- Site loads very slow for archive custom post type page
- How can I get WordPress CPT archives and page templates to work with prettified permalink settings?
- Remove the “View” Link in Post edit Admin
- Have two (permalinks) urls for a same custom post type
- How to display the FAQ Archive page in my menu
- How can I set up the URL for a category archive for a custom post type?
- 2 loops in archive.php (one for each category)
- Create a Page Templete to Display Table Of Content for Custom Taxonomies
- Using post type archive page for taxonomy archive
- Custom Post Types using wrong template (index) instead of archive-{type}.php – previously worked as expected