Go Back   vb.org Archive > vBulletin Modifications > Archive > Modification Graveyard
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
X newposts in Y threads Details »»
X newposts in Y threads
Version: 2.00, by Mr Blunt Mr Blunt is offline
Developer Last Online: Sep 2006 Show Printable Version Email this Page

Version: 3.5.0 Beta 3 Rating:
Released: 06-29-2005 Last Update: Never Installs: 12
Uses Plugins Template Edits
 
No support by the author.

##############################################
##############################################

THIS HACK CHANGED TOO MUCH!!
IT'S NO LONGER A PLUGIN!!
New Thread ... New File!!
Old removed to help eliminate confusion!!
Please visit the new thread!!!


https://vborg.vbsupport.ru/showthread.php?t=95264

I'll leave this old post and thread here for reference purposes.

##############################################
##############################################

I'm sure this is worked to death already, but I make mine a little differently. It grabs the new posts (via dateline time) but it grabs the threads (via lastpost time). This makes it slightly more intuative as it will show the number of posts found in "X threads" instead of "X newthreads".


Ohhh, and this one doesn't use a phrase.
So if you don't like english I guess you shouldn't use this.


Contents:
One plugin to upload (runs two queries in global).
One line of code to add to navbar template.

The line of code and instructions are in the included readme file.


updated to v2 already
----------------------------
Now uses Link14716's single query, but I added a conditional to set 0 if no new posts.

Also added screenshot

Supporters / CoAuthors

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #12  
Old 08-01-2005, 07:25 PM
Cheertobi Cheertobi is offline
 
Join Date: Aug 2004
Location: Germany
Posts: 178
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hi,

just two short questions, what about posts that are made in forums, a user has no access to? Are these posts also counted? What about a users own posts, are these also counted?!

Regards,

Tobi
Reply With Quote
  #13  
Old 08-01-2005, 08:45 PM
Mr Blunt Mr Blunt is offline
 
Join Date: Jan 2004
Posts: 133
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Cheertobi
Hi,

just two short questions, what about posts that are made in forums, a user has no access to? Are these posts also counted? What about a users own posts, are these also counted?!

Regards,

Tobi
Unfortunately, Yes and Yes.
I'll see if I can tweak that somehow.
Hmmmmmm
Reply With Quote
  #14  
Old 08-02-2005, 08:19 PM
ogden2k's Avatar
ogden2k ogden2k is offline
 
Join Date: Apr 2003
Posts: 192
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hi, is there a way to bold the number of threads/posts if they are new and not bold when there's only 0?

I tried with the PHP, but am not too familiar with with it.
Reply With Quote
  #15  
Old 08-24-2005, 08:25 AM
Mr Blunt Mr Blunt is offline
 
Join Date: Jan 2004
Posts: 133
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by ogden2k
Hi, is there a way to bold the number of threads/posts if they are new and not bold when there's only 0?

I tried with the PHP, but am not too familiar with with it.
Sorry, I didn't even see this reply until now!!
This would be a little tricky, but yes, anything can be done with conditionals.

conditionals are things like "if statements" for those wondering:
HTML Code:
<if condition="$newposts">
    Do this
<else />
    Do that
</if>
These TEMPLATE conditionals can be nested amost anywhere in html.
So to make JUST THE NUMBER be bold IF that number is not zero:
HTML Code:
<br /><span class="smallfont"><a href="search.php?$session[sessionurl]do=getnew"><if condition="$newposts"><b>$newposts</b><else />$newposts</if> New Posts</a> in $newthreads Threads.</span>
If you want to make ALL THE TEXT bold IF that number is not zero:
HTML Code:
<br /><span class="smallfont"><a href="search.php?$session[sessionurl]do=getnew"><if condition="$newposts"><b></if>$newposts New Posts</a> in $newthreads Threads.<if condition="$newposts"></b></if></span>
And it would be just as easy, if not easier to just completely eliminate the display IF there are no new posts as this eliminates the need for the ELSE half of the statement (since the other condition is to "do nothing").
HTML Code:
<if condition="$newposts"><br /><span class="smallfont"><a href="search.php?$session[sessionurl]do=getnew">$newposts New Posts</a> in $newthreads Threads.</span></if>
There's 3 completely different examples.
Hope that didn't confuse you too much.
If so, say so.



P.S. - As for previous request of hiding non viewable posts ... sorry I'm taking so long but I've devoted a ton of time to to another very intricate hack of mine because developing THAT is teaching me a ton of stuff which will help me design other small tweaks such as this with much better code.

Along my travels, I did find another hack that accomplishes something similar (forgot which for now but I'll get back to it when I'm ready) but I refuse to implement it until I either get permission from other author to do so and/or I learn enough to develope something like that on my own without having to cut n paste from someone elses work (meaning I fully understand the code).
Reply With Quote
  #16  
Old 08-24-2005, 08:57 AM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Mr Blunt
Unfortunately, Yes and Yes.
I'll see if I can tweak that somehow.
Hmmmmmm
Actually, the

visible = 1

should take care of that shouldn't it?
Reply With Quote
  #17  
Old 08-24-2005, 10:38 AM
Mr Blunt Mr Blunt is offline
 
Join Date: Jan 2004
Posts: 133
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Boofo
Actually, the

visible = 1

should take care of that shouldn't it?
I'm probably wrong but I always assumed visible was 1 unless the post is soft deleted.

I think the counts they want to hide are posts in private subforums like a Moderator's Forum or such for example which (I THINK) requires checking user and/or forum permissions somewhere along the line.

I think it was a hack by Paul M where I saw something like this, but don't quote me.
Reply With Quote
  #18  
Old 08-24-2005, 06:19 PM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

PM me and I can give you the single query I used in my forumhome stats cache hack for vB 3.0 for this. I think it handled private forums like it should be.
Reply With Quote
  #19  
Old 08-29-2005, 10:45 AM
Mr Blunt Mr Blunt is offline
 
Join Date: Jan 2004
Posts: 133
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Boofo
PM me and I can give you the single query I used in my forumhome stats cache hack for vB 3.0 for this. I think it handled private forums like it should be.
I finally have a response to the last PM.
A discussion about what is/isn't neccessary in the file would be great.
My opinion ... I think we need something a little more along the lines of this.
As you'll see, ummmm, I didn't use your query.

Click Me to goto Blunts Welcome Member & Guests hack thread
:banana:
Whole New Product ....
It evolved too far to keep in here as a plugin.

How should I kill this old thread??
Delete the file and put a redirect in the top post??
A few people have this installed so I don't think deleting the thread is the answer.

What do guys normally do in this situation??
Reference is always a nice thing I think.

I changed the hack's name BECAUSE I'm thinking this might expand someday beyond just post/thread counts so the old name won't really suit my needs and I figure sooner is better than later.

Quote:
Originally Posted by Cheertobi
Hi,

just two short questions, what about posts that are made in forums, a user has no access to? Are these posts also counted? What about a users own posts, are these also counted?!

Regards,

Tobi
Click Me to goto Blunts Welcome Member & Guests hack thread
New Hack has a New Answer to your questions!!

1) If the can't see the post, then the post isn't part of the counts.
2) Test this and let me know how it goes.

Quote:
Originally Posted by ogden2k
Hi, is there a way to bold the number of threads/posts if they are new and not bold when there's only 0?

I tried with the PHP, but am not too familiar with with it.
Click Me to goto Blunts Welcome Member & Guests hack thread

I took a different route for now, but we can still tweak things if anyone offers up some opinions on the new hack. There are 3 lines of text now, for 3 different search types. If the number would be zero, then I don't display the line at all. Let me know what you think.
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 02:58 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.05331 seconds
  • Memory Usage 2,303KB
  • Queries Executed 26 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (4)bbcode_html
  • (7)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (4)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (9)post_thanks_box
  • (9)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (9)post_thanks_postbit_info
  • (8)postbit
  • (9)postbit_onlinestatus
  • (9)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete