How To Change the Width of the Forum List Columns

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Jake Bunce
    Senior Member
    • Dec 2000
    • 46598
    • 3.6.x

    [Any Version] How To Change the Width of the Forum List Columns

    I tested the old instructions on version 3.5 and they appear to work exactly the same. No changes are needed. Here are the same instructions, they are just cleaned up a bit:

    Possible applications:

    To adjust the column widths you need to account for 100% of the horrizontal space. If you don't account for 100% of the horrizontal space then the widths have a tendency to shift around.

    Go to your:

    Admin CP -> Styles & Templates -> Style Manager -> « » -> Forum Home Templates -> FORUMHOME

    Find this code and notice the pieces that are highlighted in red. If you have applied the How To Put A Space Between Each Forum Category mod, then you will find the below code in the forumhome_forumbit_level1_nopost template instead:

    Code:
    	<tr align="center">
    	  <td class="thead">&nbsp;</td>
    	  <td class="thead" [color=red]width="100%"[/color] align="$stylevar[left]">$vbphrase[forum]</td>
    	  <td class="thead" [color=red]width="175"[/color]>$vbphrase[last_post]</td>
    	  <td class="thead">$vbphrase[threads]</td>
    	  <td class="thead">$vbphrase[posts]</td>
    	  <if condition="$vboptions['showmoderatorcolumn']">
    	  <td class="thead">$vbphrase[moderator]</td>
    	  </if>
    	</tr>
    Notice how not all of the table cells (<td> tags) have width attributes. You need to give each cell a width attribute, and the total widths need to equal 100% of the horrizontal space. Percentages work well for this. Here is an example of what you might use:

    Code:
    	<tr align="center">
    	  <td class="thead" [color=blue]width="5%"[/color]>&nbsp;</td>
    	  <td class="thead" [color=blue]width="50%"[/color] align="$stylevar[left]">$vbphrase[forum]</td>
    	  <td class="thead" [color=blue]width="25%"[/color]>$vbphrase[last_post]</td>
    	  <td class="thead" [color=blue]width="10%"[/color]>$vbphrase[threads]</td>
    	  <td class="thead" [color=blue]width="10%"[/color]>$vbphrase[posts]</td>
    	  <if condition="$vboptions['showmoderatorcolumn']">
    	  <td class="thead" [color=blue]width="0%"[/color]>$vbphrase[moderator]</td>
    	  </if>
    	</tr>
    Notice how the total width is 100%. The above example assumes you are not using the Moderator column. If you have the moderator column enabled then you need to give it a piece of the pie.

    You also need to make the same change to this template (unless you have applied the How To Put A Space Between Each Forum Category mod in which case that code might not be there):

    Admin CP -> Styles & Templates -> Style Manager -> &#171; &#187; -> Forum Display Templates -> FORUMDISPLAY

    In addition, some people notice that the column widths still don't match up after applying this mod. This is sometimes caused by the last post titles being too long such that the Last Post column is stretched. You can shorten those titles by adjusting this option:

    Admin CP -> vBulletin Options -> Forum Listings Display Options -> Last Thread Title Maximum Displayed Characters
    Last edited by Jake Bunce; Sat 1 Oct '05, 12:15pm.
widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
Working...