View Full Version : Moving Posts, Threads, Last Post Around?
Force011
08-31-2010, 07:50 PM
Image below shows what I am trying to do, as you can see Threads, Posts and Last Post are in the correct place, and the table width is set correctly, the only thing thats not working is the info under the sections to be in the right category.
For example, the number of posts should be under post, number of threads should be under threads, and the last post should be under last post. Unfortunately, last post is under threads, threads are under posts and posts are under last post.
http://img208.imageshack.us/img208/4057/62355192.jpg
BirdOPrey5
08-31-2010, 08:40 PM
In forumdisplay template just move the "Threads" phrase and "Last Post" phrase...
In the default template the code looks like this:
<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center">
<thead>
<tr align="center">
<td class="thead"> </td>
<td class="thead" width="100%" align="$stylevar[left]">$vbphrase[forum]</td>
<td class="thead">$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>
</thead>
$forumbits
</table>
Force011
08-31-2010, 11:00 PM
I tried doing what you said, but it didn't change anything, they are still in the same place as before.
--------------- Added 1283299500 at 1283299500 ---------------
Also my mistake in the picture, the last thread should be under last post, not posts.
BirdOPrey5
08-31-2010, 11:15 PM
What page (URL) are you viewing in that screen shot? Is it http://yourdomaincom/forums/forumdisplay.php ?
Force011
09-01-2010, 01:52 AM
That screenshot is on index.php, I assumed I would need to edit the template bit in forumhome, but none of my changes worked.
Also I do not have a forumdisplay.php.
BirdOPrey5
09-01-2010, 02:20 AM
If it's index then yes it's forumhome not forumdisplay template...
but you should also have a forumdisplay.php - what version of VB do you have?
Force011
09-01-2010, 11:37 AM
I have the latest, 3.8.6.
See for yourself.
http://forums.limitedition.org/forumdisplay.php
BirdOPrey5
09-01-2010, 01:20 PM
My bad, forumsdisplay.php - with an "s"
http://forums.limitedition.org/forumsdisplay.php
Force011
09-01-2010, 09:58 PM
Yeah, that works, so any idea what changes need to be made?
BirdOPrey5
09-01-2010, 11:34 PM
Yeah, that works, so any idea what changes need to be made?
Well it's pretty much the same instructions as before- in forumhome template just swap the last_post and threads text:
<!-- main -->
<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center">
<thead>
<tr align="center">
<td class="thead"> </td>
<td class="thead" width="100%" align="$stylevar[left]">$vbphrase[forum]</td>
<td class="thead">$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>
</thead>
$forumbits
<tbody>
If you say you did this and it didn't work then all I can think of is maybe you did it in a different style then the one you were using? This 'has' to work basically.
Force011
09-02-2010, 12:53 PM
Well the thing is, I don't have that in the forumhome template. Nothing from $forumbits to main exists.
BirdOPrey5
09-02-2010, 03:19 PM
If you view source the code is somewhere:
<tbody id="collapseobj_forumbit_1" style="">
<tr align="center">
<td class="thead" width="4%"> </td>
<td class="thead" width="62%"align="left">Forum</td>
<td class="thead" width="5%">Threads</td>
<td class="thead" width="5%">Posts</td>
<td class="thead" width="23%">Last Post</td>
</tr>
<tr align="center">
<td class="alt2"><img src="limited/statusicon/forum_old.png" alt="" border="0" id="forum_statusicon_2" /></td>
<td class="alt1Active" align="left" id="f2">
Maybe it's in another template? If you go to "Search Templates" and look for:
$vbphrase[threads]
That should list all templates with that code in it.
Force011
09-02-2010, 03:32 PM
I think I might have created a misunderstanding, I am not trying to move the category itself over, the categories Theards, Posts, Last Post are in the right places, I am trying to move the content under those categories in the correct place.
If I were to move what you stated over it would look the way it was before.
Basically my forum should be made as Forums (under that lists the forums), Threads (under that lists the threads), Posts (under that lists the posts), and finally Last Post (under that lists the latest post by the user).
I am not trying to switch the categories, just the content under the categories.
BirdOPrey5
09-02-2010, 05:22 PM
Now I understand, you want to move the content not the titles... Hmm... I THINK you have to edit the php file for that, index.php in this case- but honestly not sure. I would look for $forumbits in the php file and see if you can change the order it's "put together" - backup the file of course before testing.
Force011
09-02-2010, 06:52 PM
Now I understand, you want to move the content not the titles... Hmm... I THINK you have to edit the php file for that, index.php in this case- but honestly not sure. I would look for $forumbits in the php file and see if you can change the order it's "put together" - backup the file of course before testing.
I tried both index.php and forumsdisplay.php and nothing, I don't see any reference to anything I can change :(. Forumsbits shows up, but I don't know enough code to decipher what its doing.
BirdOPrey5
09-02-2010, 07:08 PM
OK you need to look at the function: construct_forum_bit
in the file includes/functions_forumlist.php
That's is the code that puts the $forumbits together.
Force011
09-02-2010, 09:47 PM
I hate to ask, but can you tell me what to change, I took a look through that section and I can't figure out what needs to be moved, I am not that good at php and there isn't really any reference towards post or thread count, just lots of references to the last post.
BirdOPrey5
09-03-2010, 12:03 AM
I looked at it myself- unfortunately I can't figure it out either. :(
Maybe someone else who is reading this thread? (anyone?)
There is a set of templates under Forum Home Templates named forumhome_forumbit_levelN_post where N is a number 1 to 4. These are used by construct_forum_bit to build $forumbits, so I think those are what you want to change.
Lynne
09-03-2010, 02:17 PM
To find the template to modify, do this - vboptions > General Settings > Add Template Name in HTML Comments > set to Yes . Then go back to your page and view the source code and you will see the name of the template called around your part of the code. (Sometimes the template is the one mentioned at the very top of the page source.)
Once you've found the template using that method, just move the variables around.
vBulletin® v3.8.12 by vBS, Copyright ©2000-2025, vBulletin Solutions Inc.