Use Sticky Posts.
In the Post editor find the “Publish” section.
Next to “Visibility” click on edit and then check the “Stick this post to the front page” option there.
Click save and you’re done.
In the loop, you can check if a post is_sticky()
.
To loop them, you can use the post__in
or post_not__in
keys for your query with a value of get_option( 'sticky_posts' );
.
There are also some Plugins in case you don’t want to dig in code.
Other options…
…would be to assign
- a special category
- a tag
- …or a custom field.
Edit:
Combine categories/tags + sticky posts.
Fetch »all get_option( 'sticky_posts' )
with a Tag of “Featured” (or inside Category “Featured”), then: ORDER BY post_last_modified_date LIMIT 10
«.
Related Posts:
- Is it possible to Schedule Attachments in WordPress?
- Hiding by default specific post status on backend list?
- How can I display a specific user’s first published post?
- What differences are there between a Privately Published post and a Draft post?
- Post: how to set created date after post has been published [closed]
- How to set a Post’s default visibility to ‘Private’ in Gutenberg?
- How publish post from pending status
- I am creating a front end dashboard where I need to show all the posts by the current user. So, I need to show posts in publish
- Keep featured content post in homepage with original order
- How to get posts published between a date and today?
- How to get post creation date?
- add action only on post publish – not update
- Changing the post date and time with function
- How to prevent posts from being published too close to each other?
- How to Display a List of Users Who Have Made at Least 1 Post?
- Let private posts stay in status “private” after edit through “editors”
- Elegant way to include only published posts with get_objects_in_term()?
- using wp_update_post on save_post
- WordPress plugin to publish to multiple remote WordPress blogs
- Post publish only hook?
- Publish pending article from front end with a button?
- How to add a “publish” link to the quick actions
- How to put last edited entry on top of the blog-post list?
- How to limit user to publish post per day and per role?
- Query posts from current year
- When a user creates a post (pending), send a confirmation link that allows them to publish
- In what sequence are the hooks fired when a post is “published”?
- Restrict the Number of Posts an Author can Publish (over time)?
- Add javascript when post is published
- Update existing post dates to random dates
- Setting post meta data to random value during post status transition / on publish
- How to change post status from publish to draft using hook in wordpress?
- Publish posts only after the condition is met
- How to display an icon when a new post is published and then remove it when a specific time past?
- How to output comments number of a post per day?
- Human Time Diff, change mins to minutes
- Enable commenting on front-end preview page for pending posts
- Display custom post types by date field
- Detect Post Type when publish_post is ran
- Custom Post Status Posts viewable to the public
- Does WordPress remove draft status automatically?
- What Can I Use To Add A Custom Button Between Publish button and Move To Trash?
- Prevent post from being published if no category selected
- Send email to user that his post has been rejected
- Can wordpress differentiate between added and updated posts?
- Fetch posts from current week (Sunday to Saturday)
- Limit number of posts a user can make per minute?
- How can a guest view the “Pending Review” Post?
- Every possible way to get data (posts) from WordPress
- publish_post conflicts with save_post
- How do I batch create revisions of all posts?
- add filter to “quick edit menu” in wordpress admin
- How to set post expiration date and time and move the page to archive after expiration [closed]
- ‘transition_post_status’ only fires when pressing “Add New”
- Notification to Admin or Author upon new post [duplicate]
- How to run a function when post is edited or updated using publish post action?
- How can I create custom button in post.php
- How to rename “Publish” metabox title in post screen
- Display post from specific date
- Get random posts between specific dates / of specific age
- Update post status from “publish” to “trash” for half of posts
- XML-RPC and post_date
- Automatically republish old posts
- count the total number of comments the user has received for his published posts
- How can I set a Post’s default visibility to private and pending review checked
- Automatically Updating Publish Date Bug
- Replace ‘published on date’ with ‘modified on date’ on Posts
- pre_get_posts query between 2 dates (date stored in custom post meta)
- how to remove dash (-) post status from post title on posts listing page wordpress
- How can I schedule a PAGE to go live at a future date/time?
- How can I show many posts an author has per week?
- How to give capability (publish contributors posts) to author role?
- If modified on same day, show only time
- Print a message if excerpt is empty after posts have been publish/update!
- How to change post status from frontend?
- Check if checkbox is marked on publish/update post
- Update all comments time to random dates?
- Decide user that can publish a post
- How to switch wordpress post status between publish and schedule in MySQL?
- Posts and Attachments with “Published” status in Search
- Prevent scheduled post being published if date/time is past current date/time
- WordPress Sidebar menu for posts based on date – guidance needed
- Calling Different Custom Post Timestamps in a table
- Admin – create custom post status and display above table
- How to display only feautured/sticky listings on the homepage
- Restrict edit, but allow preview for custom post status
- WordPress capabilities on pending post status
- date issue with category post retrival
- Copy post to separate database with “add_action(….)”
- Do action on publish or update?
- transition_post_status hook doesn’t have any POST data when publish with Gutenberg [closed]
- How to get date of post when using wp_get_recent_posts()?
- How to automate featured posts number? [duplicate]
- How do I manage my users post before publish?
- Worpdress function for difference dates
- do more action after I publish a post
- why there are so many posts whoes post_type is revision? will these records waste too much database space?
- $post->post_type not working
- how can i allow users to view their own pending posts in a front-end page
- Assign published posts to another user automatically