Welcome, Guest. Please Login or Register.
May 10, 2025, 04:10:54 PM
Home Help Search Log in Register
News: If you are still using YaBB SE, please consider upgrading to SMF as soon as possible.

YaBB SE Community  |  Development  |  Mod Ideas and Creation  |  show date under topic starter « previous next »
Pages: [1] Reply Ignore Print
Author Topic: show date under topic starter  (Read 531 times)
jenigma
Noobie
*
Posts: 33


crazy is as crazy does

WWW
show date under topic starter
« on: March 09, 2003, 05:59:48 PM »
Reply with quote

Hi. Here's a super simple one for someone (although not so simple I can figure it out myself unfortunately): How do I show the date a topic was started under the poster's name on the Message Index?

Thanks.
« Last Edit: March 09, 2003, 06:08:30 PM by jenigma » Logged
[Unknown]
Global Moderator
YaBB God
*****
Posts: 7830


ICQ - 179721867unknownbrackets@hotmail.com WWW
Re:show date under topic starter
« Reply #1 on: March 09, 2003, 06:22:32 PM »
Reply with quote

I like this mod.

<edit file>
Sources/MessageIndex.php
</edit file>

<search for>
      $result = mysql_query("
         SELECT t.ID_LAST_MSG, t.ID_TOPIC, t.numReplies, t.locked, m.posterName, m.ID_MEMBER, IFNULL(mem.realName, m.posterName) AS posterDisplayName, t.numViews, m.posterTime, m.modifiedTime, t.ID_FIRST_MSG, t.isSticky, t.ID_POLL, m2.posterName as mname, m2.ID_MEMBER as mid, IFNULL(mem2.realName, m2.posterName) AS firstPosterDisplayName, m2.subject as msub, m2.icon as micon, IFNULL(lt.logTime, 0) AS isRead, IFNULL(lmr.logTime, 0) AS isMarkedRead
         FROM {$db_prefix}topics as t, {$db_prefix}messages as m, {$db_prefix}messages as m2
</search for>

<replace>
      $result = mysql_query("
         SELECT t.ID_LAST_MSG, t.ID_TOPIC, t.numReplies, t.locked, m.posterName, m.ID_MEMBER, IFNULL(mem.realName, m.posterName) AS posterDisplayName, t.numViews, m.posterTime, m.modifiedTime, t.ID_FIRST_MSG, t.isSticky, t.ID_POLL, m2.posterName as mname, m2.ID_MEMBER as mid, IFNULL(mem2.realName, m2.posterName) AS firstPosterDisplayName, m2.subject as msub, m2.icon as micon, IFNULL(lt.logTime, 0) AS isRead, IFNULL(lmr.logTime, 0) AS isMarkedRead, m2.posterTime AS startedPosterTime
         FROM {$db_prefix}topics as t, {$db_prefix}messages as m, {$db_prefix}messages as m2
</replace>

<search for>
               <td class="windowbg2" valign="middle" width="14%" bgcolor="' . $color['windowbg2'] . '">
                  <font size="2">' . $mname . '</font></td>
<search for>

<replace>
               <td class="windowbg2" valign="middle" width="14%" bgcolor="' . $color['windowbg2'] . '">
                  <font size="2">' . timeformat($row['startedPosterTime']) . '<br />' . $txt[525] . $mname . '</font></td>
</replace>


That should be it.

-[Unknown]
Logged
jenigma
Noobie
*
Posts: 33


crazy is as crazy does

WWW
Re:show date under topic starter
« Reply #2 on: March 09, 2003, 06:43:35 PM »
Reply with quote

Hi Unknown. I tried it and got these errors:

Parse error: parse error, unexpected T_STRING in /home/poemki/public_html/community/Sources/MessageIndex.php on line 265

Fatal error: Call to undefined function: messageindex() in /home/poemki/public_html/community/index.php on line 310
Logged
[Unknown]
Global Moderator
YaBB God
*****
Posts: 7830


ICQ - 179721867unknownbrackets@hotmail.com WWW
Re:show date under topic starter
« Reply #3 on: March 09, 2003, 07:00:11 PM »
Reply with quote

You changed more than I said.... line 265 should be:

            LEFT JOIN {$db_prefix}log_mark_read AS lmr ON (lmr.ID_BOARD=$currentboard AND lmr.ID_MEMBER=$ID_MEMBER)

PS: This is for 1.5.1.

-[Unknown]
Logged
jenigma
Noobie
*
Posts: 33


crazy is as crazy does

WWW
Re:show date under topic starter
« Reply #4 on: March 10, 2003, 11:21:23 AM »
Reply with quote

I got it now, thanks very much.

;D

Logged
Pages: [1] Reply Ignore Print 
YaBB SE Community  |  Development  |  Mod Ideas and Creation  |  show date under topic starter « previous - next »
 


Powered by MySQL Powered by PHP YaBB SE Community | Powered by YaBB SE
© 2001-2003, YaBB SE Dev Team. All Rights Reserved.
SMF 2.1.4 © 2023, Simple Machines
Valid XHTML 1.0! Valid CSS

Page created in 0.214 seconds with 21 queries.