You just need to set the operator
parameter to 'NOT IN'
(see Codex on tax queries).
Untested, but for your purposes:
$args = array(
'post_type'=> 'post',
'post_status' => 'publish',
'order' => 'DESC',
'tax_query' => array(
array(
'taxonomy' => 'post_format',
'field' => 'slug',
'terms' => array( 'post-format-aside' ),
'operator' => 'NOT IN'
)
)
);
Related Posts:
- Exclude Current Post from Recent Posts Loop
- How to query posts to include specific pages of one post type, and all pages of another post type?
- Next Posts Prev Posts for Standard post format only
- How to get all posts in gallery post format template
- How do I get posts by multiple post ID’s?
- What does setup_postdata ($post ) do?
- Query for custom post type? [closed]
- setup_postdata() does not seem to be working?
- Regenerate Slugs From Title of Posts
- get_posts – get all posts by author id
- Why get_posts are only showing five posts (retrieved by assigning a category to them?
- Only get_posts of certain post formats
- Is it necessary to reset the query after using get_posts()?
- WordPress get_posts by category
- get_post random and order by not working
- WP_Query vs get_posts
- Alternative to get_posts() due to multithreading cache crash
- exclude category from get_posts?
- How to get current post ID in quick edit callback
- How to return results of a get_posts() in explicitly defined order
- Exclude the category from the WordPress loop
- get_posts with meta_compare=’LIKE’ not working
- get_template_part in for loop
- How to restore deleted pages/posts?
- Sort “get_pages” by menu order not ordering
- get comments and get posts in loop
- How-to exclude terms from the main query the most performant way?
- get posts based on meta value of the author
- date_query not returning some posts in date range
- Get the exact SQL query that get_posts() generated
- How do you get posts by meta_query using the JSON API plugin?
- Why favour the standard WP loop over iterating over (new WP_Query())->get_posts()?
- Query posts ordering by title, but ignore ” and special characters
- get_posts inside cron
- Retrieving 3 latest post from each of 5 different custom post types
- get_posts not honoring post_status
- get_posts returning empty array
- How to exclude categories from recent posts, recent comments & category widgets?
- get_posts only children from certain parents
- Problem with get_posts, tax_query and counting the number of posts
- Alter secondary loop to exclude posts from current page category
- Post Loop not Returning Permalink
- Loop through two different sets of custom fields
- get_posts cannot grab from specific category
- get_posts() seemingly ignoring post_type
- Filtering custom post type query
- Get posts that matches specific terms of multiple custom taxonomies
- exclude custom post type by meta key in wp_query
- Check If posts exist in custom post type category, outside of loop
- data returned from get_post($postId) have different keys than wp-json/wp/v2/posts/{postId}
- How to limit get_posts()?
- Dynamically excluding current page id
- meta_query date and time comparisons
- get_posts from post x(offset=>x) to end
- With get_posts(), how can I put a category as a variable
- What’s the difference between “get_posts” and “wp_get_recent_posts” when used with “setup_postdata”?
- Serialized array, grab specific posts with meta_key/meta_value[0]->is_featured
- How do I combine these 2 queries
- get_posts gives different result than wpdb->get_results
- Increase the page size of the WordPress REST API
- How to generate a list of posts published on current day?
- Trouble using get_post
- Cache Get_posts
- Is get_posts() more efficient than The Loop?
- Adding Pagination on a Custom Author Page
- Get latest posts from multiple categories
- get_posts() returns all posts rather than the ones specified with ‘post_author’ =>
- How do I exclude posts by custom field value?
- Query random post from different categories
- Get_Posts, only if in both categories
- Exclude custom taxonomy tag from loop
- Posts not showing in correct Alphabetical or ID order when using get_posts / orderby but only on production server
- get_posts() excluding all children of a specific post/page
- Get posts for last working week in WP_Query
- Secondary Query Is Breaking Main Query
- Advanced Custom Fields: Post Object – Not returning data [closed]
- Post Format single-loop.php using get_template_part
- If clauses in get_posts query
- var_dump and print_r cause white screen
- `get_posts()` ignore my custom post
- excluding current post from get_posts
- Only retrieve posts where post_excerpt has been filled out
- Can I use numberposts=-1 and offset together when using get_posts()?
- Filtering post-formats from the loop using new WP-Query();
- Ordering posts in get_posts
- Get first URL from post content
- How to get_posts where ‘menu_order’ is more than 0/zero?
- get_next_post() and get_previous_post() return wrong posts
- show a post from a specific post format
- I don’t arrive to do order_by title when i have a conditionnal year in a request
- How can I display a single post link, based on title sample and change monthly?
- get_posts that match a user-specified value on a page
- Display the_content on click jquery
- Inserting custom data to the_post() during loop
- What is the maximum number of posts a WordPress loop can work with?
- How do I restart my loop with get_next_post()?
- Why only one post (and no pagination) on this variation of the loop?
- get_posts() doesn’t consider user permissions
- Query Posts Exclude Entire Category
- Meta query: get posts with value in a multidimensional array