Ability to custom define topic "preview text"

Is it possible to change the preview snippet displayed for a topic?

I would like to be able to specify what is written here.

1 „Gefällt mir“

The only way to do that is to make sure the first text in the topic is what you want to be the preview.

1 „Gefällt mir“

Thanks Jeff.

Is it possible to specify a cutoff, such that in my example only the first sentence shows in the preview?

But isn’t that the only place you see that text? It’s from the category description when you edit the category. So if you edit it down to what you want will that not work?

Not quite, I’m asking in regard to the preview shown for topics, not categories.

It sounds a lot like you’re looking for excerpts in the way that CMS such as WordPress offers.

What’s your use case?

Oh gotcha. I hadn’t realised you COULD get a preview for topics. I might see if our users want that. Thanks and sorry for butting in!

1 „Gefällt mir“

I’m trying out hosting our documentation articles in one section of the forum so that it’s all in one place instead of having users bounce between the separate Docs and Forum sites. In this case I would like to be able to exercise a little more control to be able to clearly tell people what to do in that preview.

1 „Gefällt mir“

Technically @sam built a version of this as an experiment a while back (where you could explicitly mark begin and end excerpts in the first post) but I am not sure it survived into current versions of Discourse.

2 „Gefällt mir“

No problem. I consider a product a success when the support questions revolve around small details and nitpicks instead of “it’s on fire!” or “why is it not working!?!?!?” - and I love Discourse.

Thanks Jeff.

4 „Gefällt mir“

Yeah we have 2 versions that work, a div with the class excerpt or a span with the class excerpt

<div class="excerpt">
<span class="excerpt">

We use it in discourse code review, cause it makes oneboxes look way prettier

11 „Gefällt mir“

That certainly did the job.

Before:

After:

Editor:

Thank you Sam!

5 „Gefällt mir“

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.