Skip to content
Public Ticket #1377

Custom excerpt length not working

Conversation thread

manonvanos replied

Customer Reply

Never mind, I already found a solution!

manonvanos replied

Customer Reply

Hi,

Thank you so much, that worked. 

How can I now change te excerpt from the standard layout as well, so that it's not so short? I want that to show more words than what it is now.

Thanks

PenciDesign replied

Staff Reply

Hi,

Yeah, because you've built your posts by use shortcodes from Visual Composer - and wordpress will remove all shortcodes in the excerpt - so, the excerpt doesn't display.

If you want to do that, I think you need to edit the file in this theme.

Please replace this code on this image to this code:

\
<?php echo wp_trim_words( get_the_excerpt(), 20, '...' ); ?>

This will make your excerpt auto trim for 20 words, this will work even you fill custom excerpt to your excerpt box.

Hope this help,

Best Regards,

PenciDesign

manonvanos replied

Customer Reply

Hi,

Thanks for the reply.

I deleted my post excerpt in the edit post screen for the blogs 'Travel Story | De paradijselijke Gili eilanden' and 'Travel Story | Het onontdekte Indonesië in Lombok'. 

But as you can see on my website, the excerpt for the first blog (standard layout) is way too short and with at the second blog (grid layout) there isn't even an excerpt showing!

I just want it to show 20 words in the grid layout, and a bit more words on the standard layout.

Thanks

PenciDesign replied

Staff Reply

Hi,

This issue caused by you did fill your custom excerpt to excerpt box in edit posts screen.

And when you do that, wordpress doesn't supports cut the excerpt.

Best Regards,

PenciDesign

manonvanos started the conversation

Conversation Start

Hi,

I just switched my website to Soledad and am loving it so far!

I have one question about the excerpt lengt: Under 'Other Layout Option' I typed in 20, so I would expect that the excerpt under my posts on the homepage would only have 20 words. However, nothing changes when I apply 20 words to it. As you can see on my website, the full excerpt is still showing which is much more than 20 words. 

How can I change this?

Thanks.

Kind regards,
Manon van Os

Want to join this conversation or access attachments? Sign in first.