GazCBG

Registered
Hi,

I am trying to change the look of my home page, which is using 'Pages' with various modules on it and some text.

The main change I want to make is with the 'New Threads' widget using Expanded display style;.

1. I would like to limit how many words are displayed per post with a Read More link to the post (I did this a few years back but not sure how on XF1).

2. I would like to remove the line under the title with Username Date Posted Forum posted in a Replies, but only on this page, not the forum itself.

Thanks.
 
Last edited:

GazCBG

Registered
Problem 2 sorted out by adding this in the page code, for that page only.
Code:
<xf:css>
.message-attribution{display:none}
</xf:css>
 

GazCBG

Registered
Worked it out now :)

Code:
{{ bb_code(snippet($post.message, 500), 'post', $post) }}
How do I add the Read More link to this?
 
Last edited:

Russ

Pixel Exit Staff
Worked it out now :)

Code:
{{ bb_code(snippet($post.message, 500), 'post', $post) }}
How do I add the Read More link to this?
There should already be a Continue reading... link at the bottom if the post is too long, is that not showing for you?
 

GazCBG

Registered
Hi,

There is no read more links on either Default or FA+.
I editted the widget_new_threads template.

Thanks
 

Russ

Pixel Exit Staff
I suppose below your bb_code snippet edit, just add:

Code:
<a href="{ link('forums', $thread.Forum) }}" class="button">Read more</a>
does that work for you?
 

GazCBG

Registered
Hi,

Yes it does but had to add an extra { before link for it to work, but all good now.
I have:

Code:
<a href="{{ link('threads', $thread) }}" class="button" style="float:right;">Read more</a>
Thank you :)
 

Pre-Sale Questions

If you have any questions or concerns you want to ask before you make a purchase don't hesitate to use one of our multiple support channels for your convenience.