'post_id'
is not a valid page/post parameter for WP_Query()
. Try using p
or post__in
instead:
array(
'p' => 700
)
or
array(
'post__in' => array(
700
)
)
Related Posts:
- Order by multiple meta key and meta value [closed]
- Query posts only with featured image
- Order by optional meta key?
- get_query_var function not working at all
- get_query_var( ‘paged’ ) not working outside of homepage
- WP_query to get the first two latest posts, then another loop to get the next three
- Why is WP_Query not working with category_name?
- ‘Trying to get property of non-object’ when using WP_Query with ‘fields’ => ‘ids’
- Order by Category and Post in WP custom Query
- Execute a large WP_Query with many “AND” Meta_Queries?
- Get attachment by slug
- RSS feed with specific keyword
- Get All IDs Of A Post Type Using WP_Query
- Group posts by custom field
- Multiple endpoints in one URL
- getting posts and number by specific meta value in multiple meta
- How to query using a combination of custom_field values?
- how to fire join query with post_meta
- Show one post per author and limit query to 8 posts
- Get term by custom term meta and taxonomy
- Generate a tabbed submenu — from taxonomy term or submenu item — with sample content
- wp_query with multiple custom fields
- Removing posts from the returned wp_query. Cannot use object of type WP_Query as array
- So strange result of wp_query and have_posts
- How to detect if a function has been fired on any page so scripts/styles can be loaded conditionally
- Why execute the_post()?
- $wpdb insert is not work
- WP_Query Ignoring `post_type` parameter
- How to get the WC_Product Object when using a WP_Query in WooCommerce
- get_posts – find out if querystring was crap and fallback is used
- Custom Search Result Page displaying only 1 result.
- How to query a custom post type with a taxonomy filter but display post type archive page?
- How to display 7 most recent days of posts?
- WP_Query Variable inside Array
- Create A Loop With A Variable Number of Posts For Each Bootstrap Row?
- Set Transient does nothing
- Get amount of CPT with a certain custom field value
- The pagination on index.php doesn’t work on a first page
- Include tags in WP_Query
- How do I make a meta_query OR relation work? [closed]
- WordPress multisite – fallback on subsites to main site on 404 and dealing with switch_to_blog function
- Count author posts in certain category
- How to use wp_query to post count by search term > group post count by date > convert to json. (ex. result 12-21-2020 – 343)
- Taxonomy Query Relation field not behaving correctly?
- Woocommerce – Changing the order of the upsell products [closed]
- How to output topics and replies in bbpress as table?
- twentyeleven_content_nav hook no longer outputs navigation link after 3.5 upgrade
- how to access query string in wordpress?
- How to get all post except particular category without breaking the paging
- How do I rewrite this loop as a new WP_Query style-loop?
- Pagination only won’t work in author template
- ACF Query Structure
- Can’t sort custom post type by random
- exclude product with available tag
- WP_Query meta value order is not working
- How to get main menu only with wp_nav_menu
- relation OR instead of AND – Filtered term ID’s in loop
- How to get specific string in explode array?
- filter posts by meta key with pagination
- Single post – display list of all posts + specific post
- Ajax (jquery) wp_query pagination returns -1
- Modify output of custom loop using WP_query
- What’s wrong with this wpdb query?
- The Events Calendar, wp_query returning event date not published date
- Query to get result by Title or Meta along with tax_query parameter
- Oxygen Repeater Advanced Query
- SQL query injection with fifu image
- How do I use multiple similar queries with WP_Query on the same page?
- Use dedicated functions
- WPQuery Date and ACF
- Pagination not working on archive.php template?
- Save large WP_Query to transient === false
- 3 posts from each existing category on one page
- How to show specify category template for both parent and child category
- WP_Term_Query->get_terms() very slow query for WordPress filter
- WordPress search page pagination displaying but not functional
- Get all wp_users sort by metakey
- query all posts published by certain user id
- How to create URL parameters to run custom queries?
- How to use wp_query in different column in single loop
- Paginated Post List on Front Page
- Query custom meta value – post view and date meta
- modifying the loop multiple times with arguments passed through ajax to wp_query
- WP_Query – show posts where meta value and user_email match
- WP_Query causing links to not work
- Website goes slow down after importing long database
- Orderby Date and Category
- Pagination for custom query throws 404 errors on last pages [duplicate]
- Order posts by custom column using pre_get_posts
- wp_query in form method of widget breaks customizer
- Featured image not showing on page
- Add filter to Orderby Parameter using Array
- Iterate through ID’s in loop
- Need help setting up a search form for wordpress [duplicate]
- Including ‘cat’ => $cat breaks meta_query
- problem in query_vars parameters
- Limit Tags display and ad Drop Down Menu
- Add banner after the third post [closed]
- How to retrieve _embed (etc) fields in get_posts custom query?
- Is there another way to retrieve a post_id from post_meta other than a SQL query?