inherit
239147
0
Jan 27, 2019 3:15:54 GMT -8
theclash
52
November 2016
theclash
|
Post by theclash on Jan 30, 2017 17:24:51 GMT -8
Apologies in advance if I am posting this in the wrong area! Me & my members love the Recently Updated Posts page; most of my members are involved with all boards, and as such it is their go to TAB when they land on the forum. Problem is, there are many posts that could relate to different boards so it can be a tad confusing Is there any way to include the board name alongside the post title (ideally only implemented in the Recently Updated Posts TAB). Alternatively any plugin/ code or ideas that would show which board each post belongs to. Thanks In Advance Guys
|
|
inherit
I need a new CT, thinking.... [insert Jeopardy theme song here]
110769
0
Aug 21, 2021 0:07:21 GMT -8
Tumbleweed
20,825
September 2007
tumbleweed
|
Post by Tumbleweed on Jan 31, 2017 21:37:20 GMT -8
I did move your thread to templates as you can see as it should be just an easy template addition but I must be having a brain fart because this should work but it doesn't. (Added to the post list template)
{if $[route.name] == "recent_posts"}Board: $[post.thread.board.display_name]{/if}
That is supposed to be just showing it on the recent posts and not in the actual posts but I'm doing something wrong with the recent_posts part I guess? If I remove the if stuff it shows the board on the posts but on regular posts and recent posts.
I'll look at it again tomorrow when maybe my brain is working and maybe I'll see what I'm doing wrong. I thought I'd post it here in case you wanted to dabble with it as well.
|
|
inherit
239147
0
Jan 27, 2019 3:15:54 GMT -8
theclash
52
November 2016
theclash
|
Post by theclash on Feb 1, 2017 4:21:37 GMT -8
I did move your thread to templates as you can see as it should be just an easy template addition but I must be having a brain fart because this should work but it doesn't. (Added to the post list template) {if $[route.name] == "recent_posts"}Board: $[post.thread.board.display_name]{/if} That is supposed to be just showing it on the recent posts and not in the actual posts but I'm doing something wrong with the recent_posts part I guess? If I remove the if stuff it shows the board on the posts but on regular posts and recent posts. I'll look at it again tomorrow when maybe my brain is working and maybe I'll see what I'm doing wrong. I thought I'd post it here in case you wanted to dabble with it as well. You're a star! - appreciate your help and look forward to see what you come back with
|
|
inherit
239147
0
Jan 27, 2019 3:15:54 GMT -8
theclash
52
November 2016
theclash
|
Post by theclash on Feb 1, 2017 17:22:46 GMT -8
Had a little play around, and made it work! {if $[route.name] == "all_recent_posts"} Board: $[post.thread.board.display_name]{/if} Thanks Tumbleweed for pointing me in the right direction!
|
|
inherit
I need a new CT, thinking.... [insert Jeopardy theme song here]
110769
0
Aug 21, 2021 0:07:21 GMT -8
Tumbleweed
20,825
September 2007
tumbleweed
|
Post by Tumbleweed on Feb 1, 2017 19:25:36 GMT -8
Had a little play around, and made it work! {if $[route.name] == "all_recent_posts"} Board: $[post.thread.board.display_name]{/if} Thanks Tumbleweed for pointing me in the right direction! I wouldn't of ever thought of "all_recent_posts". Big kudos to you! I bet you did a happy dance.
|
|
inherit
239147
0
Jan 27, 2019 3:15:54 GMT -8
theclash
52
November 2016
theclash
|
Post by theclash on Feb 2, 2017 5:47:35 GMT -8
Slight bug - the board name is only appearing on the first page (on the Recently Updated Posts page)!
Any ideas?
|
|
inherit
239147
0
Jan 27, 2019 3:15:54 GMT -8
theclash
52
November 2016
theclash
|
Post by theclash on Feb 2, 2017 15:49:31 GMT -8
Strangely, if I go to page 2 and refresh the page the board name appears (then back on page 1, it has disappeared!)
If I remove the IF function, it works. However, it shows on all posts; ideally I would prefer it implemented on the Recently Updated Posts. It seems that the IF functioned requires a manual refresh?
What's going on?
|
|
inherit
I need a new CT, thinking.... [insert Jeopardy theme song here]
110769
0
Aug 21, 2021 0:07:21 GMT -8
Tumbleweed
20,825
September 2007
tumbleweed
|
Post by Tumbleweed on Feb 2, 2017 21:38:14 GMT -8
Strangely, if I go to page 2 and refresh the page the board name appears (then back on page 1, it has disappeared!) If I remove the IF function, it works. However, it shows on all posts; ideally I would prefer it implemented on the Recently Updated Posts. It seems that the IF functioned requires a manual refresh? What's going on? I'm sorry, TheClash, I just don't know enough about how recent posts work to know why it is doing that and I'm also not so great at if statements. I didn't notice before but it also does it on my test site. Give this a bump in 24 hours and if no one else jumps in, I'll flag some red names that know this stuff down pat.
|
|
inherit
Official Code Helper
65613
0
1
Oct 22, 2024 1:56:19 GMT -8
Chris
"'Oops' is the sound we make when we improve"
9,018
December 2005
horace
RedBassett's Mini-Profile
|
Post by Chris on Feb 3, 2017 6:47:03 GMT -8
The act of changing pages modifies the route from 'all_recent_threads' to 'list_posts' thus making it indistinguishable from a list of posts within a thread when you do a page change there. I'm almost sure the $[viewing_recent_posts] variable was created to address that very problem
{if $[viewing_recent_posts]} Board: $[post.thread.board.display_name]{/if}
Note: whenever there is an AJAX transaction ( such as changing pages or liking a post) the route changes to reflect the most recent action.
|
|
inherit
239147
0
Jan 27, 2019 3:15:54 GMT -8
theclash
52
November 2016
theclash
|
Post by theclash on Feb 3, 2017 15:41:03 GMT -8
Thanks Chris - works a treat! Made my day
|
|
inherit
140147
0
Nov 19, 2024 5:07:22 GMT -8
Nscalerr
Throw me to the wolves and I'll return leading the pack!
3,043
May 2009
nscalerr
|
Post by Nscalerr on Feb 4, 2017 18:27:43 GMT -8
Been following along with this and have it all working, but I was wondering if the same could be done for Recent Threads. The follwoing is what I have already, except it only shows on page 1.
{if $[route.name] == "recent_threads"} — <span style="font-size: 7pt; color: #8B795E;">Board: <a href="$[thread.board.link.href]">$[thread.board.display_name]</a></span>{/if}
|
|
inherit
Official Code Helper
65613
0
1
Oct 22, 2024 1:56:19 GMT -8
Chris
"'Oops' is the sound we make when we improve"
9,018
December 2005
horace
RedBassett's Mini-Profile
|
Post by Chris on Feb 4, 2017 23:19:15 GMT -8
Nscalerr there is no corresponding $[viewing_recent_threads] variable for the thread view that would do the same as it did for the post view. This would require the addition of the variable by Proboards
|
|
inherit
140147
0
Nov 19, 2024 5:07:22 GMT -8
Nscalerr
Throw me to the wolves and I'll return leading the pack!
3,043
May 2009
nscalerr
|
Post by Nscalerr on Feb 4, 2017 23:45:17 GMT -8
|
|
Former Member
inherit
guest@proboards.com
195316
0
Nov 28, 2024 19:37:43 GMT -8
Former Member
0
January 1970
Former Member
|
Post by Former Member on Feb 5, 2017 3:35:56 GMT -8
|
|