Glossary Term
get_posts_by_author_sql()
3 tags
1 category
get_posts_by_author_sql() — Retrieves the post SQL based on capability, author, and type.
Inputs: $post_type (string|string[]): Single post type or an array of post types. $full (bool): Optional. Returns a full WHERE statement instead of just an ‘andalso’ term. Default true. $post_author (int): Optional. Query posts having a single author ID. Default null. $public_only (bool): Optional. Only return public posts. Skips cap checks for $current_user. Default false.
Returns string: SQL WHERE code that can be added to a query.
Term Connections
Explore related terms connected by shared tags, shared categories, and relationship phrases. This map loads only when it comes into view.
Loading term connections…
