Excerpts are short texts or summaries

learn more… | top users | synonyms

0
votes
3answers
33 views

How to get post or page excerpt using post_excerpt

I am using the following foreach loop: $pages = get_pages(array ('post_type' => 'page','sort_column' => 'menu_order',)); foreach ($pages as $page) { $apage = $page->post_name; ...
0
votes
2answers
70 views

How can i show only 30% of the “the_content(”More…“)”?

I'm trying to make a page that has all the posts in it and shows 30% or less of the content of the post. So I'm editing a page template and I can't figure out how to show only 30% of the content. I'm ...
0
votes
2answers
218 views

truncate post with gallery tag

I have one problem I use this function for truncate posts function truncate_post($amount,$quote_after=false) { $truncate = get_the_content(); $truncate = apply_filters('the_content', $truncate); ...
0
votes
2answers
389 views

Create custom links for excerpts with php dynamically

Good Day I am using excerpts in my wordpress theme. Now in wordpress's documentation, they say wordpress does not automatically add links for the excerpts, you have to manually add them like this: ...
0
votes
2answers
3k views

Customizing get_the_excerpt() to specific length and “Read More” output.

I am costuming a template. There is a list grabbing the introduction from the first 1-2 paragraphs (all the articles from a category). If I set the excerpt to 295 words, sometimes the list grabs ...
1
vote
1answer
96 views

Move excerpt meta box to above content editor

I found a WordPress hook called "edit_form_after_title" to add a text box after the title. How can I use this hook to display the excerpt after the title while creating a new post?
1
vote
1answer
383 views

Allowing the SoundCloud player to appear in a post excerpt

I am setting up a website for my music, in conjunction with my SoundCloud account. I plan to post the links to my soundcloud player as blog posts, but I can't figure out how to make the blog excerpts ...
1
vote
1answer
103 views

Give “Read More” precedence over excerpt() word count

By default, the_excerpt() displays the content before the <!--more-->, trimming it at ~50 words. Is there any way to prevent this trimming functionality when the <!--more--> is present, ...
0
votes
1answer
31 views

Why the_excerpt() function returns excerpt on the Home page and trimmed content in sidebar?

I have this code to display 4 posts of type "testimonial" on the Home page: <?php $custom_posts = get_posts([ 'numberposts' => 4, 'post_type' => ...
0
votes
1answer
16 views

Return only content in excerpt field in loop

I am sure this has been asked before, but I can't seem to find the answer, although it seems simple enough. I have built a custom theme based on another person's design. He uses both the excerpt and ...
0
votes
1answer
65 views

Custom wp_trim_words() function not trimming right

I have this custom wp_trim_words() function set to give me excerpts of only 20 words, and for the most part, it works fine. Except for some reason, on posts that contain lists, it outputs way more ...
0
votes
1answer
34 views

image class removed in excerpt

I have inline images in my post content that have classes. the classes are available as I go to single page like this: <img src="the_cource.jpg" class="myclass"> , but are removed as I look ...
0
votes
1answer
37 views

How to remove excerpt white spaces

This is my code in wordpress archive: mb_substr(get_the_excerpt(), 0, 236); This echos: NGÀY 1: HÀ NỘI – ĐÀ NẴNG Chiều: khởi hành In view code NGÀY 1: HÀ NỘI – ĐÀ NẴNG ...
0
votes
1answer
90 views

Wordpress excerpt with formatting and allowing selected tags

I went through your answer in post Issue with enabling formatting in excerpts in Wordpress. It works fine and closes tags so that a tag does not spill over to other posts. But I need to disable images ...
0
votes
1answer
124 views

How to stop unwanted splits in excerpts when using shortcodes for sliders or players

Am using this code in functions.php: Issue with enabling formatting in excerpts in Wordpress to allow shortcodes, javascript and formatting in the excerpt - works great, thanks. However, I am also ...
0
votes
1answer
151 views

Can't change excerpt length and more tag

I tried to change the excerpt length and the more tag the way it is described in the codex: function custom_excerpt_length( $length ) { return 10; } add_filter( 'excerpt_length', ...
0
votes
1answer
64 views

[Plugin leenk.me]modify get_the_title

I use a plugin called leenk.me to post messages to Facebook based on my posts. One of the custom fields is %TITLE%, which posts the title of my post and the link to my post. if ( false === ...
0
votes
1answer
31 views

More link - not text

I am using origin theme. This theme writes dots in post end. In functions.php file I saw line with text: function origin_excerpt_more( $more ) { return '...'; I changed text to More... and ...
0
votes
1answer
65 views

Change image link in excerpt to point to post

By default, images included in an article link to the full-size-image url. Having such an image in an excerpt shown on the start-page, because the more-tag was added after the image (which is ...
0
votes
1answer
134 views

multiple excerpt length and styles

I am working on a site, which have many excerpt like text but with different style of read more or click here to read more with different length. is there a way i can make excerpt length according to ...
0
votes
1answer
316 views

Manual excerpt length on recent posts slider

I need to change the character/word limit of manual excerpts which will be displayed on recent posts slider. I think it's 55 characters right now without counting spaces and punctuation marks. Am i ...
0
votes
1answer
125 views

How to display page excerpt with readmore link inside an enhanced widget?

I'm trying to display an excerpt of a page inside an enhanced widget. I have tried the following but it doesn't work: <?php $id = 2550; $post = get_post($id); $content = ...
0
votes
1answer
242 views

Remove 'read more' link when post is shorter than excerpt

How can I remove the 'read more' link from a post excerpt on a blog/archive page when there is nothing more to read...when the length of the post is shorter than the excerpt?
0
votes
1answer
79 views

simple category search form returns full text - but I need excerpts

I have member pages. I set their "membership type" as a certain category. I want to search the members now. I use this simple form that does what I need, except that I need the results to display as ...
-1
votes
1answer
130 views

Excerpt all post content Content Same Size without word cutting off

On my category page there are list of 24 posts with title and excerpt content. To display specific lengths of content, I am using substr function. Now the issue is that each post excerpt content are ...
-1
votes
1answer
51 views

Using Schema with `the_excerpt`

I'm currently developing a WordPress site and want to use Schema, I have been some what successful so far but have now hit a stone wall. I want to use: itemprop="description" to the ...
1
vote
0answers
195 views

Regenerate auto excerpts after updating many posts

I had around 100 posts that I imported into my blog. Many of the special characters (e.g. apostrophes, etc) were mangled upon import. I finally went through and fixed them all manually by editing each ...
1
vote
0answers
93 views

Show excerpts of posts on P2 Home page

I am looking to show the latest posts on my site home page, which is using P2 theme. I want them to be shown in excerpts. I have found the following code on a site, it said its in the entry.php file. ...
1
vote
0answers
168 views

Excerpt formatting for Google News Feed

We're currently bringing in a Google RSS News Feed using FeedWordPress and it works great. This issue is that Google uses a defined table structure in their RSS. The excerpt function has no problem ...
0
votes
0answers
23 views

wp_trim_words is trimming by character instead of by words

I'm using Wordpress 3.9.2, and having trouble with the wp_trim_words function. It seems to be cutting the string down to X characters instead of X words. Example Put the following in a template ...
0
votes
0answers
21 views

Strip 'p' tags in wp_trim_excerpt()

When I have a lot of paragraphs in a post and trying to display an excerpt in blockquote, all <p> tags are stripped, and whole 55 words are in one <p> tag. <blockquote cite="URL"> ...
0
votes
0answers
15 views

2 posts same excerpt?

I'm facing the following problem: I'm outputting 2 posts with different titles, dates, permalinks but the excerpt are both the same. <?php $query = new WP_Query( array( 'post_type' ...
0
votes
0answers
23 views

Archive Page Isn't Showing Article Excerpts

I'm using the _tk theme (bootstrap + _s) and in the reading form I've set the Posts page to a static page because I'm using a static front page. I've also set it to show a summary for each article. ...
0
votes
0answers
222 views

Custom post type change excerpt more and excerpt length

I have written a some code to get custom excerpt_length and excerpt_more. The excerpt_length is working for both custom post type and general post. But I don't know why excerpt_more is not working for ...
0
votes
0answers
50 views

Custom search results page not showing excerpt

I have a custom content-searchresults.php page. However for some reason its not showing the excerpt, but other amends I make this on this are pulled through so it is using this template. Below is my ...
0
votes
0answers
36 views

Excerpt for each post type and for is_front_page

i try to adjust the excerpt for each post type and especially for the front page. function isacustom_excerpt_length($length) { global $post; if (is_front_page() || is_home()){ if ...
0
votes
0answers
24 views

HTML markup output issue if a custom excerpt is pulled from an advanced custom field

I've used a custom excerpt function to get an excerpt from an advanced custom field. The function inside functions.php looks like that: function custom_field_excerpt($title) { global $post; ...
0
votes
0answers
35 views

get_permalink() echoing about us page link only. how to solve this.?

I am trying to build an own theme for my wordpress site. I am using the following code to get a 3 posts on my home page. $paged = (get_query_var('paged')) ? get_query_var('paged') : 1; $args = ...
0
votes
0answers
60 views

Wordpress Next & Previous post outside the loop

As a (front) designer I'm looking for the following: How can I get the following code working for next/previous posts OUTSIDE the loop? <img src="<?php get_featured_image ?>" /> ...
0
votes
0answers
20 views

Generate excerpt (respecting <!--more--> if it's there) “by hand”

I have a post archive page that's loaded by AJAX so I am manually retrieving the posts via WP_Query and then manually displaying $post->post_content, etc. The problem is that I'm not using The ...
0
votes
0answers
109 views

Extending wordpress search to include excerpts and taxonomies?

Apologies for the lack of code, but I have no idea where to start with this - is it possible to extend Wordpress's search function to include excerpts and (custom) taxonomies as well as the standard ...
0
votes
0answers
305 views

Custom excerpt_more filter not working when <!--more--> tag is present

I'm doing this inside Thesis 2, in case that matters. I am using the_excerpt(); on my blog page to get the posts. And I'm using two custom filters: function custom_excerpt_length( $length ) { ...
0
votes
0answers
101 views

Wordpress not showing full text in feed

I have been reading around and I cannot figure out why (even with the full text option checked in settings) that my feed will only display excerpts of posts instead of full posts. Any ideas? here is ...