tax_query in pre_get_posts
tax_query in pre_get_posts
tax_query in pre_get_posts
WP Query orderby ACF boolean values and ACF field value
Support answered and said they didn’t know how to get the published date, but they would ask their team. For anyone else looking for this answer, I finally found that I can use this to get this published date: $date = mysql2date(‘F d, Y’, get_post_time(‘Y-m-d H:i:s’, true), false);
Order by post meta not working with pre_get_posts filter
wp query remove posts from query then update max pages and posts found
Hi @eeyore: Without being able to see the full context of your theme page I think you have at least two issues. You need to use $wp_query instead of $my_query if you want previous_posts_link() and next_posts_link() to work since they assume $wp_query. What @Jan Fabry mentioned; you need to capture the pagination yourself and pass … Read more
The only thing I see as even close to syntactically questionable is that showposts could be replaced with posts_per_page.
This looks like a query generated as part of the search facility within WordPress. For example, a visitor has been to your site and typed the word ‘true’ into your search box. If you have a large number of posts/pages/etc in your WordPress installation, then the only way you could optimise this query is to … Read more
Just run 2 queries, the first to pull just the new-videos and the 2nd to pull everything else but the new-videos. Probably just use WP_Query for the first one to get the new-videos and then alter the loop query for the 2nd one to exclude new-videos.
The meta query is converted by _get_meta_sql(). You can check the output by hooking into get_meta_sql. Dump that value and see what it gives.