Viewing 3 replies - 1 through 3 (of 3 total)
  • Theme Author Chris Reynolds

    (@jazzs3quence)

    You can’t (not easily, anyway). It’s part of WordPress core that post excerpts don’t include links or other html — all that is stripped out of the excerpt. So the only way around it is to use full posts (which is probably not what you are wanting to do). There is a way to output full html in a post excerpt, but it basically involves writing your own post excerpt function that outputs full HTML. And then you run into the same issue where, let’s say a link starts, but then the excerpt cuts off the post before the link text is ended — you end up with a full page that is linking to that un-closed link.

    One workaround may be to use the <!–more–> tag (available in the wysiwyg toolbar) — I don’t use it that often so I don’t know off the top of my head if that supports html (and therefore links) or not, but it does allow you to define your own post excerpt. (everything before the more tag becomes the excerpt)

    Thread Starter julesjunction

    (@julesjunction)

    Thank you so much for the quick response, I really appreciate it and you have helped because you set me thinking on a different track.

    What I have done is rather than let WordPress automatically create the excerpt from the Post, I have now written specific excerpts for each post in the ‘Excerpt’ field (which I didn’t know about before now because it was hidden and I didn’t know it existed until you mentioned it above). I have added html to this field and it displays it on the post listing. Yay!

    Thanks so much,
    Jules

    Theme Author Chris Reynolds

    (@jazzs3quence)

    Awesome. Glad that worked. ??

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘hyperlinks in post listings’ is closed to new replies.