inherit
\o/ ^o^ /o_ /o\
16464
0
Jul 22, 2024 13:57:10 GMT -8
pawl
29,621
November 2003
pollo
Pink Stars
|
Post by pawl on Dec 8, 2012 12:28:48 GMT -8
This is a little template modification that changes how boards are displayed on the main page. It puts everything in one cell, and makes the whole thing a little sleeker. Preview: clickIf you're still with me, read on. =]
All the editing you're going to do is in the Board List template; Admin Panel -> Themes -> Layout Templates -> Board -> Board List Tab Start with the header section, beginning at line 3 - just add in the purple sections; <tr> <!-- <th class="icon"></th> <th class="main">Board</th> <th class="threads">Threads</th> <th class="posts">Posts</th> <th class="latest last">Last Post</th> --> <th class="main" colspan="5">Board Stats</th> </tr>This comments out the original header row, stopping it from being displayed. Should you want it back, it will still be hidden away for you to use. Alternatively, if you want to get rid of the whole thing, move the <!-- and --> so that they are before the <tr> and after the </tr> tags, removing the entire row. Below this you'll find a <tbody> tag, finishing just below the end of the template. I chose to comment all of this out too, with the same <!-- --> as before. I replaced it by adding the following just below; <tbody> {foreach $[board]} {if !$[board.is_redirect]} <tr id="$[board.content_id]" class="$[board.content_class]"> <td class="main clickable last" colspan="5"> <table width="100%"> <tr> <td width="5%"> $[board.icon] </td> <td width="30%"> <span class="link"><a href="$[board.href]">$[board.display_name]</a></span><br /> <span class="description">Total Threads: $[board.threads]<br /> Total Posts: $[board.posts]</span> </td> <td width="65%" class="description" align="right"> $[board.description] </td> </tr> </table> </td> </tr> {else} <tr id="$[board.content_id]" class="$[board.content_class]"> <td class="icon">$[board.icon]</td> <td class="main clickable redirect last" colspan="4"> <span class="link">$[board]</span><br /> <p class="description">$[board.description]</p> </td> </tr> {/if} {/foreach} {if !$[board]} <tr class="last"><td class="last center" colspan="5">No boards were found.</td></tr> {/if} </tbody>And done! That was fairly painless, right? As ever, any problems, or if you've spotted a mistake, just post a reply. =]
|
|
inherit
186006
0
Mar 30, 2019 4:02:27 GMT -8
smashwords2
Breathing
244
November 2012
smashwords2
|
Post by smashwords2 on Jan 22, 2013 19:10:09 GMT -8
Get 2 description images, using the Board Description Images plugin, with Total Threads at top of image and Total Posts at bottom of image. I tried the <!-- and --> around the $[board.icon] and the $[board.description] but the images still overlapped. Oh crap.
What code do I need to remove or add to fix the double description?
|
|
Relic
Junior Member
Posts: 243
inherit
179570
0
Apr 9, 2014 20:02:40 GMT -8
Relic
243
May 2012
sin1993
|
Post by Relic on Jan 28, 2013 18:45:41 GMT -8
Hey pawl! This looks absolutely fantastic! Before I use it on my forum, though, I'm wondering if you've tested it with Shrike's Board Description Images plugin?
|
|
inherit
186006
0
Mar 30, 2019 4:02:27 GMT -8
smashwords2
Breathing
244
November 2012
smashwords2
|
Post by smashwords2 on Jan 29, 2013 6:37:55 GMT -8
Hey pawl! This looks absolutely fantastic! Before I use it on my forum, though, I'm wondering if you've tested it with Shrike's Board Description Images plugin?
Look at post above regarding Board Description Images.
|
|
Relic
Junior Member
Posts: 243
inherit
179570
0
Apr 9, 2014 20:02:40 GMT -8
Relic
243
May 2012
sin1993
|
Post by Relic on Jan 29, 2013 11:17:47 GMT -8
From your post, it seems like it's not compatible because it duplicates things...? Or am I wrong?
|
|
inherit
186006
0
Mar 30, 2019 4:02:27 GMT -8
smashwords2
Breathing
244
November 2012
smashwords2
|
Post by smashwords2 on Jan 30, 2013 21:01:33 GMT -8
From your post, it seems like it's not compatible because it duplicates things...? Or am I wrong? Yes, it duplicates images and messes up the Threads/Posts data and Last Post information.
|
|
inherit
167603
0
Aug 5, 2013 21:55:15 GMT -8
LifeOfWylie
261
June 2011
wylie
|
Post by LifeOfWylie on Feb 1, 2013 1:57:27 GMT -8
Another great one, pawl! I tweaked it a little to suit me, as seen below: I removed the red, which put the Threads and Posts on the same line...
<span class="description">Total Threads: $[board.threads]<br /> Total Posts: $[board.posts]</span>
...and changed the line to the blue to separate the fields:
<span class="description">$[board.threads] Threads, $[board.posts] Posts</span>
which reads as # Threads, # Posts. This reduces the box height even more! I tried a combo of the board.threads.posts, but that totaled it all together.
|
|
inherit
\o/ ^o^ /o_ /o\
16464
0
Jul 22, 2024 13:57:10 GMT -8
pawl
29,621
November 2003
pollo
Pink Stars
|
Post by pawl on Feb 14, 2013 5:08:08 GMT -8
Just a quick post to say to @smashwords1993 and Relic that I don't know how the plugin you're talking about is coded, or how it works. Best bet would be to talk to the plugin's author, and see if they know what's gone wrong. =/
|
|
inherit
159823
0
Jun 19, 2017 14:44:36 GMT -8
Tk
558
November 2010
thomask
|
Post by Tk on Mar 18, 2013 7:42:50 GMT -8
pawl I love it. Just a quick question - Is there a way to get the board description to align left? I'd rather they were under than to the side. founders-forum.proboards.com/Nevermind I did it by changing it to this: <td width="95%"> <span class="link"><a href="$[board.href]">$[board.display_name]</a></span> <span class="description">$[board.threads] Threads, $[board.posts] Posts<br /> $[board.description]</span> </td>
|
|
inherit
187104
0
Apr 26, 2016 16:18:46 GMT -8
iTehSoupi
in se dov
12
December 2012
isoupi
|
Post by iTehSoupi on Apr 29, 2013 10:51:49 GMT -8
Hello, bare with my simple and probably silly question, but after I replace Row 3 with the purple and move onto the <tbody> tag, there are several <tbody> tags in my template... Therefore, I'm confused as to which one I replace. I haven't added a single other code/template the site yet, just for your information.
|
|
inherit
167603
0
Aug 5, 2013 21:55:15 GMT -8
LifeOfWylie
261
June 2011
wylie
|
Post by LifeOfWylie on Apr 30, 2013 5:05:04 GMT -8
Hello, bare with my simple and probably silly question, but after I replace Row 3 with the purple and move onto the <tbody> tag, there are several <tbody> tags in my template... Therefore, I'm confused as to which one I replace. I haven't added a single other code/template the site yet, just for your information. In my board list, it's lines 10 - 59 that get arrowed out. The very first <tbody>, just below the </thead>.
|
|
inherit
187104
0
Apr 26, 2016 16:18:46 GMT -8
iTehSoupi
in se dov
12
December 2012
isoupi
|
Post by iTehSoupi on Apr 30, 2013 6:01:23 GMT -8
Erm... Sorry, LifeOfWylie. ^^; That doesn't really help any... It still looks exactly the same. I don't know if I'm just doing it wrong, or what. :B
|
|
inherit
\o/ ^o^ /o_ /o\
16464
0
Jul 22, 2024 13:57:10 GMT -8
pawl
29,621
November 2003
pollo
Pink Stars
|
Post by pawl on May 10, 2013 3:35:53 GMT -8
Hello, bare with my simple and probably silly question, but after I replace Row 3 with the purple and move onto the <tbody> tag, there are several <tbody> tags in my template... Therefore, I'm confused as to which one I replace. I haven't added a single other code/template the site yet, just for your information. Hey there iTehSoupi, sorry to have missed this for so long. Still having a problem at all? If so, just double check that you have both a <!-- and a --> added to the template for each section, as per my first post. If you're still not sure, post up your template so that we can have a look. =]
|
|
inherit
187104
0
Apr 26, 2016 16:18:46 GMT -8
iTehSoupi
in se dov
12
December 2012
isoupi
|
Post by iTehSoupi on May 12, 2013 16:41:34 GMT -8
It's precisely the "<!-- -->" that I think I'm missing/screwing up, and its the portion I don't quite understand... I still haven't been able to get it to work, despite my constant meddling. It's a biiiig change from the old template systems. xD I'm just not savvy enough with it yet to quite grasp the instructions entirely. Its just all the placement that's getting me. :B
|
|
inherit
\o/ ^o^ /o_ /o\
16464
0
Jul 22, 2024 13:57:10 GMT -8
pawl
29,621
November 2003
pollo
Pink Stars
|
Post by pawl on May 16, 2013 15:39:08 GMT -8
It's precisely the "<!-- -->" that I think I'm missing/screwing up, and its the portion I don't quite understand... I still haven't been able to get it to work, despite my constant meddling. It's a biiiig change from the old template systems. xD I'm just not savvy enough with it yet to quite grasp the instructions entirely. Its just all the placement that's getting me. :B Any chance you could post up the templates for me, iTehSoupi ? =]
|
|