Previous Thread
Next Thread
Print Thread
Rate Thread
#224983 09/23/2002 2:39 AM
Joined: Jun 2002
Posts: 375
Enthusiast
Enthusiast
Offline
Joined: Jun 2002
Posts: 375
Mod Name / Version - Last Post By v1.0

Description - Adds the post title and user name for the last post in the forum to the ubbthreads.php 'Last Post' column.

Example - http://www.newoutriders.org/ubbthreads/ubbthreads.php

Pre-requisites - none

Author - AllanAyers

Files Altered - ubbthreads.php, ubbthreads.tmpl

Database Altered - no

New Files - None

Credits: Aglavalin for typing it up, ask me for help, not Allan.

Note: This is an easy hack. Can cause excessive SQL calls, be warned on a busy server or UBBT with a large database! Works fine on 6.1 with the moderator column removed already. Otherwise you will need to modify the code to work with the moderator column still in.


This will probably work with 6.0.x, but I have not tested it myself. Perhaps Allan knows, as he wrote this code...
Attachments
57146-LastPostBy_1.0.txt (0 Bytes, 124 downloads)

Last edited by Aglavalin; 10/28/2002 2:21 PM.
Sponsored Links
neuron #224984 09/23/2002 10:44 AM
Joined: Mar 2000
Posts: 21,079
Likes: 3
I type Like navaho
I type Like navaho
Joined: Mar 2000
Posts: 21,079
Likes: 3
Thanks Aglavin Actually philipp from ntcompatible.com wrote it


- Allen wavey
- What Drives You?
Joined: Jun 2002
Posts: 375
Enthusiast
Enthusiast
Offline
Joined: Jun 2002
Posts: 375
Now ya tell me!

neuron #224986 09/23/2002 11:23 PM
Joined: Feb 2002
Posts: 1,759
Addict
Addict
Offline
Joined: Feb 2002
Posts: 1,759
Hmm.. just tried it on mine (6.1) and the moderator column was just a bunch of black cells. Something didn't work right

palmen #224987 09/23/2002 11:57 PM
Joined: Jun 2002
Posts: 375
Enthusiast
Enthusiast
Offline
Joined: Jun 2002
Posts: 375
Oh I bet that is because I removed the moderator column from my site, and I copied that code from my tmpl file, the one with no mod column anymore. Guess I should fix this hack then...

Sponsored Links
neuron #224988 09/24/2002 7:47 AM
Joined: Feb 2002
Posts: 1,759
Addict
Addict
Offline
Joined: Feb 2002
Posts: 1,759
Thanks, I had assumed that was the cause, but I was too tired to try and add that in myself

neuron #224989 10/04/2002 9:46 PM
Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
Thanks!

I've always wanted this..... but never found it.

Thought I'd seen it recently. Added it tonight... my users think it's a feature of 6.1.1. They like.

Daine #224990 10/28/2002 3:14 AM
Joined: Apr 2001
Posts: 25
Junior Member
Junior Member
Offline
Joined: Apr 2001
Posts: 25
sorry Please,

can someone help me with the mitake of the mod collum? i´m not able to do that by myself. I have the same problen with the black mod collum. If it´s possible, i want a normal mod collum and the last post by!

Thanks for helping

y board is here

Joined: Jun 2002
Posts: 375
Enthusiast
Enthusiast
Offline
Joined: Jun 2002
Posts: 375
This hack was written with the moderator column removed already, so either remove the mod column, or alter the code to make it work on one more column. I'm off working on a big site for the last serveral weeks, so I have not been doing anything ubb related...

Daine #224992 11/02/2002 6:57 AM
Joined: Aug 2002
Posts: 37
User
User
Offline
Joined: Aug 2002
Posts: 37
Hi

I just added this hack and it seems you can see the last post by: in the Main Index..but all of the forums are still the same

OR was this just made for the main index?


Lerosia


[:"red}Ifyouwanttomakeyourcomputergoreally,reallyfast,thowitoutthewindow[/color"]
Sponsored Links
Calis #224993 11/02/2002 10:21 AM
Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
There is a different "Last Post by" hack in the Finished Mods forum (posted by Just Dave) that will update the info on the postlist.php screen.

This one just does the Main Index (the ubbthreads.php file).

Daine #224994 11/02/2002 8:18 PM
Joined: Aug 2002
Posts: 37
User
User
Offline
Joined: Aug 2002
Posts: 37
Ahhh...

Again, gracias


Lerosia


[:"red}Ifyouwanttomakeyourcomputergoreally,reallyfast,thowitoutthewindow[/color"]
neuron #224995 11/03/2002 1:15 AM
Joined: Apr 2002
Posts: 68
Power User
Power User
Offline
Joined: Apr 2002
Posts: 68
Thanks. I really like this. there are some more things I wanted it to do. For example, have a link to the user profile.

[]http://www.prowrestlingforum.com/lastreply.jpg[/]

What I've done:
- Added "In:" and "by"
- Link to the users profile

I don't know if anyones done this.. oh well. here goes.

After you installed it, find in the ubbthreads.tmpl:
code:

<font class="small">
 <a href="{$config['phpurl']}/showflat.php?Cat=$Cat&Board={$forum[$c][$f]['Keyword']}&Number=$lastnumber&Main=$lastmain#Post$lastnumber" title="$lsubject">$lsubject</a>
($luser)
</font>


Replace:
code:

<font class="small">
 In: <a href="{$config['phpurl']}/showflat.php?Cat=$Cat&Board={$forum[$c][$f]['Keyword']}&Number=$lastnumber&Main=$lastmain#Post$lastnumber" title="$lsubject">$lsubject</a>
<br />By: <a href="{$config['phpurl']}/showprofile.php?Cat=&User=$luser" title="$luser's Profile">$luser</a>
</font> [/]



"We're sorta like the 7-11. We're not always doin' business, but we're always open"
Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
Excellent Idea. Thanks.

Daine #224997 11/04/2002 3:19 PM
Joined: Apr 2001
Posts: 25
Junior Member
Junior Member
Offline
Joined: Apr 2001
Posts: 25
Realy Cool

Thanks a lot

Joined: Nov 2002
Posts: 116
Journeyman
Journeyman
Offline
Joined: Nov 2002
Posts: 116
Try this in order to work both (moderator column and be aligned)

echo <<<UBBTPRINT
<tr class="darktable">
<td valign="top" width="1%">
<img src="{$config['images']}/{$forum[$c][$f]['boardfolder']}" alt="" />
</td>
<td width="60%">
<font class="forumtitle">
<a href="{$config['phpurl']}/postlist.php?Cat=$Cat&Board={$forum[$c][$f]['Keyword']}">
{$forumimage}{$forum[$c][$f]['Title']}
</a>
</font>
<br />
<table cellpadding="0" cellspacing="0">
<tr>
<td>

</td>
<td width="17%" class="forumdescript">
{$forum[$c][$f]['Description']}
</td>
</tr>
</table>
</td>
<td width="6%" align="center" class="threadtotal" nowrap="nowrap">
{$forum[$c][$f]['Threads']}
{$forum[$c][$f]['showthreads']}
</td>
<td width="6%" align="center" class="posttotal" nowrap="nowrap">
{$forum[$c][$f]['Total']}
{$forum[$c][$f]['showposts']}
{$forum[$c][$f]['showna']}
</td>
<td width="25%" nowrap="nowrap" class="posttime">
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="18" valign="bottom"> <img src="{$config['images']}/icons/$licon" align="middle" border="0" alt="" />  </td>
<td valign="bottom">
<font class="small">
 <a href="{$config['phpurl']}/showflat.php?Cat=$Cat&Board={$forum[$c][$f]['Keyword']}&Number=$lastnumber&Main=$lastmain#Post$lastnumber" title="$lsubject">$lsubject</a>
($luser)
</font>
</td></tr>

<tr><td width="18" valign="bottom"> </td>
<td valign="bottom">
<font class="small">$date
<font class="posttime">$datetime[1] $datetime[2]</font></font>
</td></tr></table>
</td>

<td width="10%" class="modcolumn" align="center">
{$forum[$c][$f]['modlist']}
</td>
</tr>

UBBTPRINT;
} //UBBTREMARK
echo <<<UBBTPRINT
<!-- END OF FORUM LOOP -->
</table>
</td>
</tr>
</table>
UBBTPRINT;
} //UBBTREMARK
echo <<<UBBTPRINT
<!-- END CATEGORY LOOP -->


Just replace it in the ubbthreads.tmpl

Joined: Oct 2002
Posts: 21
Newbie
Newbie
Offline
Joined: Oct 2002
Posts: 21
Sometimes I get a broken image (the icon) when I don't incude one (when I use a quick reply box, or don't include on in my post)


Link Copied to Clipboard
Donate Today!
Donate via PayPal

Donate to UBBDev today to help aid in Operational, Server and Script Maintenance, and Development costs.

Please also see our parent organization VNC Web Services if you're in the need of a new UBB.threads Install or Upgrade, Site/Server Migrations, or Security and Coding Services.
Recommended Hosts
We have personally worked with and recommend the following Web Hosts:
Stable Host
bluehost
InterServer
Visit us on Facebook
Member Spotlight
isaac
isaac
California
Posts: 1,157
Joined: July 2001
Forum Statistics
Forums63
Topics37,573
Posts293,925
Members13,849
Most Online5,166
Sep 15th, 2019
Today's Statistics
Currently Online
Topics Created
Posts Made
Users Online
Birthdays
Top Posters
AllenAyres 21,079
JoshPet 10,369
LK 7,394
Lord Dexter 6,708
Gizmo 5,833
Greg Hard 4,625
Top Posters(30 Days)
Top Likes Received
isaac 82
Gizmo 20
Brett 7
WebGuy 2
Top Likes Received (30 Days)
None yet
The UBB.Developers Network (UBB.Dev/Threads.Dev) is ©2000-2024 VNC Web Services

 
Powered by UBB.threads™ PHP Forum Software 8.0.0
(Preview build 20221218)