Welcome, Guest. Please Login or Register.
April 21, 2025, 03:33:05 AM
Home Help Search Log in Register
News: SMF is the next generation in forum software, almost completely re-written from the ground up, make sure you don't fall for cheap imitations that suffer from feature bloat!

YaBB SE Community  |  Development  |  Mod Ideas and Creation  |  "if posted" indicator « previous next »
Pages: [1] 2 Reply Ignore Print
Author Topic: "if posted" indicator  (Read 2102 times)
arwen8
Noobie
*
Posts: 28


I'm a llama!

"if posted" indicator
« on: August 09, 2002, 06:45:01 PM »
Reply with quote

I've recently migrated from YaBB Gold to SE- and had been using a "bold if posted" mod on the old board.  It was useful- highlighting the threads that a member had posted to... and I miss it.

I've searched for mention of a similiar mod for SE, but haven't seen anything (unless its called something completely different).

If such a mod exists, could someone refer me to it?

If one doesn't exist, I would like to try my hand at putting it together, but could use a little help with the PHP... which I will post separately in the PHP help forum.  :)

Thanks in advance!  :)
Logged
David
Destroyer Dave
Global Moderator
YaBB God
*****
Posts: 5761


I'm not a llama!

WWW
Re:"if posted" indicator
« Reply #1 on: August 09, 2002, 08:31:13 PM »
Reply with quote

Would this replace the new indicator?
Logged

arwen8
Noobie
*
Posts: 28


I'm a llama!

Re:"if posted" indicator
« Reply #2 on: August 09, 2002, 08:48:29 PM »
Reply with quote

Quote from: David on August 09, 2002, 08:31:13 PMWould this replace the new indicator?

No.  The "new" indicator would still mark all threads containing new messages... this would just highlight the threads (w/ new messages or not) that a member had posted to.

Sounds like a goofy little thing, but it IS handy to have the thread list load and have some sort of visual reminder of which ones you've been participating in.

I figure the same general logic that is used to indicate the new threads could be applied to this.  Though instead of cross-referencing with the logTime, it would simply need to connect member name with thread ID... and if they had posted to it, the thread title would show in bold (or with an image- maybe a dotfolder image)... if not, it would show in normal text.

But I've only been working with PHP for about a week now, so am not quite sure how to make it happen.  Yet, anyway.   ;)

Logged
David
Destroyer Dave
Global Moderator
YaBB God
*****
Posts: 5761


I'm not a llama!

WWW
Re:"if posted" indicator
« Reply #3 on: August 09, 2002, 11:34:50 PM »
Reply with quote

NOw I understand what you mean.  Like vB does where it puts a dot on the post icon.
Logged

arwen8
Noobie
*
Posts: 28


I'm a llama!

Re:"if posted" indicator
« Reply #4 on: August 10, 2002, 04:23:48 AM »
Reply with quote

Quote from: David on August 09, 2002, 11:34:50 PMNOw I understand what you mean.  Like vB does where it puts a dot on the post icon.

Exactly.  Like I said... goofy little feature, but very helpful- and surely not too hard to do.  It'll be my weekend project- unless someone beats me to it.

:)
Logged
Gobalopper
Mod Team
YaBB God
*****
Posts: 993


Cookie Monster

WWW
Re:"if posted" indicator
« Reply #5 on: August 10, 2002, 10:13:10 PM »
Reply with quote

This should do it:

               // check if user has posted in this thread
                $postcheck = mysql_query( "SELECT ID_MSG FROM yabb_messages WHERE ID_TOPIC = '$mnum' AND ID_MEMBER = '$ID_MEMBER' LIMIT 1" );
                if( mysql_fetch_array( $postcheck ) ) {
                  $msub = "<strong>".$msub."</strong>";
                }
Logged
arwen8
Noobie
*
Posts: 28


I'm a llama!

Re:"if posted" indicator
« Reply #6 on: August 11, 2002, 04:40:00 AM »
Reply with quote

Quote from: Gobalopper on August 10, 2002, 10:13:10 PMThis should do it:

               // check if user has posted in this thread
                $postcheck = mysql_query( "SELECT ID_MSG FROM yabb_messages WHERE ID_TOPIC = '$mnum' AND ID_MEMBER = '$ID_MEMBER' LIMIT 1" );
                if( mysql_fetch_array( $postcheck ) ) {
                  $msub = "<strong>".$msub."</strong>";
                }

NICE!!!!  You're a beautiful person- thank you!   :-*

Just a note to anyone else who might want to use it... it goes in messageindex.php and you might have to change the "yabb_messages" to "whatever_messages" if you've given your database fields a different prefix.

And again- thank you!   ;D
Logged
Gobalopper
Mod Team
YaBB God
*****
Posts: 993


Cookie Monster

WWW
Re:"if posted" indicator
« Reply #7 on: August 11, 2002, 04:48:36 AM »
Reply with quote

Oops I forgot about that. yabb_messages could also be {$db_prefix}messages. That will work regardless what you have called your tables.
Logged
sylvester
YaBB God
*****
Posts: 525


Re:"if posted" indicator
« Reply #8 on: August 11, 2002, 01:56:48 PM »
Reply with quote

so, if there are 50 topics shown @ the message-index, it will use 50(FIFTY) extra mysql-queries. That isn't nice ;) 8) :P
« Last Edit: August 11, 2002, 06:00:03 PM by sylvester » Logged

I'm back
Nemesis
What's an Admin?
Global Moderator
YaBB God
*****
Posts: 2199


WWW
Re:"if posted" indicator
« Reply #9 on: August 11, 2002, 05:45:04 PM »
Reply with quote

Welcome to the modding zone... Where all the queires you can save is a life saver!
Logged


Want to say thanks?
*************************************
DONATE or check out my WishList
*********************************
arwen8
Noobie
*
Posts: 28


I'm a llama!

Re:"if posted" indicator
« Reply #10 on: August 11, 2002, 09:40:11 PM »
Reply with quote

Quote from: sylvester on August 11, 2002, 01:56:48 PMso, if there are 50 topics shown @ the message-index, it will use 50(FIFTY) extra mysql-queries. That isn't nice ;) 8) :P

Wow!  Do people actually set their boards to display that many topics?   :o

But yeah... I don't imagine that this feature would be practical for a large board- or for one that allows guest posting.

My board is small and doesn't have guest access, however.  Also, I keep things streamlined and have removed a lot of non-essential features for the sake of both speed and being gentle on the server.

So it's not an issue in my case... but it's good that folks with bigger full-featured boards consider the implications of using this mod on their own boards.

 :)
Logged
sylvester
YaBB God
*****
Posts: 525


Re:"if posted" indicator
« Reply #11 on: August 11, 2002, 09:56:22 PM »
Reply with quote

Quote from: arwen8 on August 11, 2002, 09:40:11 PM
Quote from: sylvester on August 11, 2002, 01:56:48 PMso, if there are 50 topics shown @ the message-index, it will use 50(FIFTY) extra mysql-queries. That isn't nice ;) 8) :P

Wow!  Do people actually set their boards to display that many topics?   :o

But yeah... I don't imagine that this feature would be practical for a large board- or for one that allows guest posting.

My board is small and doesn't have guest access, however.  Also, I keep things streamlined and have removed a lot of non-essential features for the sake of both speed and being gentle on the server.

So it's not an issue in my case... but it's good that folks with bigger full-featured boards consider the implications of using this mod on their own boards.

 :)
ok, let's say you show 10 topics, then it will use 10 queries ONLY to check if you've posted in that topic or not.  ::) :P 8)
Logged

I'm back
arwen8
Noobie
*
Posts: 28


I'm a llama!

Re:"if posted" indicator
« Reply #12 on: August 11, 2002, 10:27:50 PM »
Reply with quote

Quote from: sylvester on August 11, 2002, 09:56:22 PMok, let's say you show 10 topics, then it will use 10 queries ONLY to check if you've posted in that topic or not.  ::) :P 8)

LOL!  Well... all I can say is that if it disturbs you so much, then you shouldn't use it!   ;D

But as I said, my board is small (average of about 6-7 users at a time and most ever simultaneous users being 17), so I'm not exactly frying the server with this.

To each, her own... right?  :)
Logged
sylvester
YaBB God
*****
Posts: 525


Re:"if posted" indicator
« Reply #13 on: August 11, 2002, 10:38:35 PM »
Reply with quote

Quote from: arwen8 on August 11, 2002, 10:27:50 PMTo each, her own... right?  :)
Right :)
Suit yourself ;) 8) :)
End of discussion ;D
Logged

I'm back
groundup
Disciple of Joe, Head Cleric
Mod Team
YaBB God
*****
Posts: 2983


Error 309: Please notify the administrator of this

WWW
Re:"if posted" indicator
« Reply #14 on: August 12, 2002, 01:08:09 AM »
Reply with quote

what you don't understand is that there is about 20 queries for the messageindex.  Using another 10 could pose a large load on your server.  The admin area uses 32, but people don't use that every minute.
Logged

http://www.fastfinancialfreedom.org - financial freedom is a myth
http://www.fastfinancialfreedom.org - financial freedom is a myth
http://www.fastfinancialfreedom.org - financial freedom is a myth
fastfinancialfreedom.org
Pages: [1] 2 Reply Ignore Print 
YaBB SE Community  |  Development  |  Mod Ideas and Creation  |  "if posted" indicator « 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.049 seconds with 16 queries.