Archived topic
GeneratePress / SEOPress Meta Description
1 reply · Started by Carl on January 7, 2023
Hi - for SEOPress, you can set the meta description to pull in the post excerpt, which they code as %%post_excerpt%%. When I do this, I get the caption of the first photo and some text from the first paragraph as an excerpt. I'm trying to figure out how to ignore the image caption, pull in the initial text/paragraph and limit it. I reached out to SEOPress, and they said it's something handled by the site theme.
Hi there,
I reached out to SEOPress, and they said it’s something handled by the site theme.
To cover: %%post_excerpt%% is a variable that is registered with the SEO Press plugin.
Presumably that string is replaced with the excerpt via a function of the SEO Press plugin.
If that function was returning the same excerpt that the theme outputs then it would not have the caption ( you can see that in the post archives, or rather you can't see the caption :) )
I had a look at their documentation and i did find this:
https://www.seopress.org/support/hooks/filter-excerpt-length-metas/
Which is filter that looks and sounds like it is setting their excerpt length. Which means they must have a function that is getting their excerpt.
So... Can you ask them how exactly it is related to the theme?
If theres something we can do then let us know :)