[HowTo] Tweaking the $postbit template
What does this one do?
When you view a thread, each post might have an attachment, a signature, the report/ip links and could hold 'edited by' line. But they aren't sticky to the bottom of the table cell, and they are not in their right place (that is what I think).
This tweak will put the content of the postbit into its own table which makes it possible to align them properly, give those elements their own place in the postbit template and lets you set the height to 100%, so it can stick to the bottom of the cell. The result is a cleaned up version of the default postbit template, a tweak.
Why did you make it?
Personally, I was hoping vBulletin was default by this, but unfortn. not, and I guess they have their reasons for it. But still, I wanted this, and I had a lot of users requesting me if I could make it. After a few horrible failures, here it is. So I hope it is good enough. And maybe in time, it gets better! I just thought it was smart to share my first successful attempt.
(note: this is not working 100% in all browsers, so consider it beta until I tag it otherwise) (22-05-2002 @ 14:00)
(update 1: 22-05-2002 @ 23:45)
(update 2: 21-07-2002 @ 22:45)
So far I have been able to get this to work in Internet Explorer 6.0 and Mozilla 1.x for 100% - I did not find any incorrect alignments and placing of the cells.
I have not been able to get this to work in Opera 6.02 - 0% - stupid browser!
I won't even bother checking in Netscrape. Since they use same engine etc as Mozilla.
I will also clean up this post in the future. But for now, let's just share this as I have it working on my site.
The support for this is going as far as I can get it to work. So be sure you have a backup of a working template for your board (Don't just trust that [revert to original], otherwise I wouldn't be getting those damn PM's every day by users asking for it)
Ok, here goes.
Installation steps:
1- postbit template > [change original] (or [edit]) and find:
2- replace that part with:
3- Save the template
Done!
Version?
Tested with vBulletin 2.2.6 and works just great! - on default test board (localhost) and on my public board (which is a little bit more modded).
The Result
Check the next two posts.
Feel free to post improvements (as long as they are clear and don't require code-hacking (for that, goto vBulletin.org please) ok)
What does this one do?
When you view a thread, each post might have an attachment, a signature, the report/ip links and could hold 'edited by' line. But they aren't sticky to the bottom of the table cell, and they are not in their right place (that is what I think).
This tweak will put the content of the postbit into its own table which makes it possible to align them properly, give those elements their own place in the postbit template and lets you set the height to 100%, so it can stick to the bottom of the cell. The result is a cleaned up version of the default postbit template, a tweak.
Why did you make it?
Personally, I was hoping vBulletin was default by this, but unfortn. not, and I guess they have their reasons for it. But still, I wanted this, and I had a lot of users requesting me if I could make it. After a few horrible failures, here it is. So I hope it is good enough. And maybe in time, it gets better! I just thought it was smart to share my first successful attempt.
(note: this is not working 100% in all browsers, so consider it beta until I tag it otherwise) (22-05-2002 @ 14:00)
(update 1: 22-05-2002 @ 23:45)
(update 2: 21-07-2002 @ 22:45)
So far I have been able to get this to work in Internet Explorer 6.0 and Mozilla 1.x for 100% - I did not find any incorrect alignments and placing of the cells.
I have not been able to get this to work in Opera 6.02 - 0% - stupid browser!
I won't even bother checking in Netscrape. Since they use same engine etc as Mozilla.
I will also clean up this post in the future. But for now, let's just share this as I have it working on my site.
The support for this is going as far as I can get it to work. So be sure you have a backup of a working template for your board (Don't just trust that [revert to original], otherwise I wouldn't be getting those damn PM's every day by users asking for it)
Ok, here goes.
Installation steps:
1- postbit template > [change original] (or [edit]) and find:
Code:
<td bgcolor="$post[backcolor]" width="100%" valign="top"> <smallfont>$post[icon] <b>$post[title]</b></smallfont> <p><normalfont>$post[message]</normalfont></p> $post[attachment] <p>$post[signature]</p> <p>$post[editedby]</p> <p align="right"><smallfont><a href="report.php?s=$session[sessionhash]&postid=$post[postid]">Report this post to a moderator</a> | $post[iplogged]</smallfont></p> </td>
2- replace that part with:
Code:
<td bgcolor="$post[backcolor]" width="100%" height="100%" valign="top"> <table width="100%" border="0" cellpadding="0" align="left" height="100%"> <tr> <td bgcolor="$post[backcolor]" colspan="2" align="left" valign="top" height="20"><smallfont>$post[icon] <b>$post[title]</b></smallfont></td> </tr> <tr> <td bgcolor="$post[backcolor]" colspan="2" align="left" valign="top"><p><normalfont>$post[message]</normalfont></p></td> </tr> <tr> <td bgcolor="$post[backcolor]" colspan="2" align="left" valign="bottom" >$post[attachment]$post[signature]</td> </tr> <tr> <td bgcolor="$post[backcolor]" align="left" valign="bottom" height="8"><br>$post[editedby]</td> <td bgcolor="$post[backcolor]" align="right" valign="bottom" height="8"><br><smallfont><a href="report.php?s=$session[sessionhash]&postid=$post[postid]">Report this post to a moderator</a> | $post[iplogged]</smallfont></td> </tr> </table> </td>
3- Save the template
Done!
Version?
Tested with vBulletin 2.2.6 and works just great! - on default test board (localhost) and on my public board (which is a little bit more modded).
The Result
Check the next two posts.
Feel free to post improvements (as long as they are clear and don't require code-hacking (for that, goto vBulletin.org please) ok)
Comment