get_the_content()
does what it’s supposed to, gets the content. You’re looking for get_the_excerpt()
. 😉
Alternatively, using what you have, it should cut off wherever you put <!-- more -->
in your post when using get_the_content()
.
Related Posts:
- Get Posts Under Custom Taxonomy
- Stop WordPress automatically adding tags to post content
- How to show related posts by category
- WordPress removing tags?
- get_children() Not Working with orderby Parameter
- How to get all posts related to particular category name?
- How to know if get_posts() failed?
- How to display posts by current user/author in a custom page template?
- Show the title of the latest post by author
- Setting pagination for images attached to a post
- Query only Posts from Both of Two Category?
- WordPress get posts by date without query_posts
- How to add shortcode tags in single.php [closed]
- How To Add Perfect Apostrophe And Quotation Mark In WordPress Posts?
- Adding variable for post title so post template can include auto-generated link to view on external website.com/{post title}
- Hide Post comments when displayed via WP_Query
- Posts are not showing up on particular category
- get selected post using $_GET
- Can I set and show “important” post in my blog?
- setup_postdata doesn`t seem ot be working
- Get Posts via Taxonomy Term Name with Space
- Get specific posts by ID in wordpress
- Automatically republish old posts
- get_next_post() and get_previous_post() return wrong posts
- Duplicating Table of Contents for Paginated Post
- Query how many items to show in shortcode
- Get posts by name and taxonomy term
- Inserting custom data to the_post() during loop
- How do I restart my loop with get_next_post()?
- Get mixed category random posts
- WordPress not opening posts with only numbers if permalink is post_name
- Limit popular posts by days
- Is there a straight-forward way to iterate over all shortcodes in a post?
- How to display Common posts from specific Tag & Category with Shortcode
- Post Loop Missing Most Recent Post
- Get Posts Under Custom Taxonomy
- What’s the best way to render Visual Composer in posts, not pages?
- Shortcode and whitespace formatting problem
- Shortcode to display the latest news article within a page
- Posts loop displaying the same post data
- Shortcodes on my website stops working after theme update [closed]
- How to get posts from a current post’s month?
- How to get posts and comments amount per hour, per year and per month?
- While loop articles – if statement order
- Count number of posts of current month
- How to get ID of the page included with get_page()?
- How to Get Posts, Including Private Ones?
- Random posts from a pool of posts
- How to get a post’s details by shortcode?
- Conditional Tag for has post [closed]
- Why posts array is empty?
- How to create a “latest news” page showing a list of posts from blog category
- Post Filtering by GET URL parameters
- How come a YouTube link isn’t transformed into a shortcode inside the post content?
- Custom Articles page only showing a limited number of posts per page
- Related Posts function not working
- How to get post with slug and exclude categories
- Why aren’t paragraphs breaking on this page?
- Get x recent posts by author?
- HTML Inside of Shortcode Breaks Shortcode Output
- If post does not exist, do something
- Internal linking to posts permalink fail because of spaces and stripe at postname
- Get posts from current category?
- post/page content
- How to add content above footer in posts from specific category
- What parameters do I need to pass to get_tags to get ALL tags for the site, when used in a post
- Shortcode for Comments and Comment Boxes in Post Loop
- shortcode // get posts by ids
- get posts, run a custom query, and join the results
- Display “no post” message
- How can I create a shortcode to show the number of posts of actual day?
- How to pull sticky post permalink inside php?
- Display Post from Custom Post Type with Shortcode
- wp_insert_post() Add and specific ID to the body of that
- How to mark only one post as Featured post?
- REST API Working for GET but not for POST?
- Fill the exclude array() in get_posts()
- How to add navigation arrows to manually slide through posts?
- How to convert return type of ‘get_posts()’ same as ‘wp_get_recent_posts()’?
- How to get all posts in gallery post format template
- How to get the current user post and it’s ID?
- Add category attribute to custom recent post shortcode
- Using Post ID and Page ID in same function
- Retrieve latest post by multiple categories with ID
- External link not showing on post but showing on comment
- How do I paginate posts page with $wpdb?
- How to get all post titles starting with numbers and symbols?
- Bulk Attach Or Insert Media To Post Without Opening Post Editor
- Change the default video URL in a post to shortcode format
- How to get single post by one author?
- get_posts includes “auto drafts”?
- get value from post to sidebar
- If post has non-shortcode string
- wordpress show category link instead of post link [closed]
- Display posts from another page on home page in wp-editor
- Trying to create shortcode listing custom posts, but formating not being included
- posts_per_page – Repeats only first posts ‘post__in’ array
- NewsPaper WP Theme – Additional Related Posts Filter by Time (divTag composer)
- View post with specific category id and name which I selected in the backend (drop-down option)
- Undefined Function Fatal Error with Shortcode [closed]