Previous Thread
Next Thread
Print Thread
Rate Thread
Joined: Nov 2001
Posts: 1,704
C
CTM Offline OP
Moderator / Da Masta
OP Offline
Moderator / Da Masta
C
Joined: Nov 2001
Posts: 1,704
Modification Name: Post Count-Restricted Forums 3.1.0

Author(s): CTM

Description: Allows Administrators to restrict access to a forum by post count. Restriction is via Forum Settings section in Control Panel, and an unlimited number of forums can be set in this way. Administrators and Moderators of the post count-restricted forums can bypass the post count limit, in the same way that they are able to bypass other forum restrictions. Unauthorised users may not search post count-restricted forums or see their Recent Visitors information. Fully Wordlet-ised for easy modification and translation.

Demo: None

Requirements: UBB.classic 6.7.0 or higher

Download Link: Contact privately

Credits: Allen and Gizzy, for pushing me hard enough to release this wink

Updates:
Version 3.1.0:
Fixed small Recent Visitors loophole (thanks Ian Spence) - If you're using v3.0.0 find and remove the following in ubb_lib_pntf.cgi:

Code
&& (&UBB::LIB::PostCountRestriction($in->{f}) == 1)
Notes: So here it is, the updated version of PCRF at long last. Fixed all bugs from the 2.0.0 series, including that horrible Recent Visitors bug and all the Search bugs (as far as I can see). Thanks again to Allen, Gizzy and Ian Spence for encouraging me to get this done. Sorry I had to make you wait so long. frown

This mod might work on 6.6.x, but I'm not going to make it official until someone tries (I don't use 6.6 any more so I don't have anywhere to test it; if you do get it working on 6.6 then I'd be very grateful if you could tell me so others could know too).

Bug reports/problems/comments/flames all welcome, but please keep them in this topic because my PM inbox needs to be cleaned out first. Thanks smile

Sponsored Links
Joined: Mar 2000
Posts: 21,079
Likes: 3
I type Like navaho
Offline
I type Like navaho
Joined: Mar 2000
Posts: 21,079
Likes: 3
muchas gracias... very requested by a few wink


- Allen wavey
- What Drives You?
Joined: Jan 2000
Posts: 5,819
Likes: 16
UBBDev / UBBWiki Owner
Time Lord
Offline
UBBDev / UBBWiki Owner
Time Lord
Joined: Jan 2000
Posts: 5,819
Likes: 16
Who, me? :X... GJ wink ..


UBB.Dev - Putting Dev into UBB.threads
Company: VNC Web Services - UBB.threads Scripts and Scripting, Install and Upgrade Services, Site and Server Maintenance.
Forums: A Gardeners Forum, Scouters World, and UGN Security
UBB.Threads: My UBB Themes, My UBB Scripts
Joined: Nov 2001
Posts: 1,704
C
CTM Offline OP
Moderator / Da Masta
OP Offline
Moderator / Da Masta
C
Joined: Nov 2001
Posts: 1,704
Link to mod updated, the previous one was depricated earlier this afternoon. Sorry for any inconvenience caused to those trying to download this for a few hours earlier today. smile

Joined: Mar 2001
Posts: 7,394
L
LK Offline
Admin / Code Breaker
Offline
Admin / Code Breaker
L
Joined: Mar 2001
Posts: 7,394
Good job, the code looks very well. smile

Quote
quote:
UBBDev - Putting the "Ultimate" into Ultimate Bulletin Board
We're really into making a new motto, aren't we wink

Sponsored Links
Joined: Jan 2000
Posts: 5,819
Likes: 16
UBBDev / UBBWiki Owner
Time Lord
Offline
UBBDev / UBBWiki Owner
Time Lord
Joined: Jan 2000
Posts: 5,819
Likes: 16
I liked mine...
"UBBDev, where you too can render your fresh UBB.Classic install completely useless"


UBB.Dev - Putting Dev into UBB.threads
Company: VNC Web Services - UBB.threads Scripts and Scripting, Install and Upgrade Services, Site and Server Maintenance.
Forums: A Gardeners Forum, Scouters World, and UGN Security
UBB.Threads: My UBB Themes, My UBB Scripts
Joined: Nov 2001
Posts: 1,704
C
CTM Offline OP
Moderator / Da Masta
OP Offline
Moderator / Da Masta
C
Joined: Nov 2001
Posts: 1,704
Ian Spence has found a problem that is caused by my code when users are not logged in and try to view a forum or topic. This problem is now fixed (PCRF v3.0.1). If you're using v3.0.0 find and remove the following in ubb_lib_pntf.cgi:

Code
&& (&UBB::LIB::PostCountRestriction($in->{f}) == 1)
Thanks Ian smile

Joined: Jan 2000
Posts: 5,819
Likes: 16
UBBDev / UBBWiki Owner
Time Lord
Offline
UBBDev / UBBWiki Owner
Time Lord
Joined: Jan 2000
Posts: 5,819
Likes: 16
Thank god i didn't install it yet :x...


UBB.Dev - Putting Dev into UBB.threads
Company: VNC Web Services - UBB.threads Scripts and Scripting, Install and Upgrade Services, Site and Server Maintenance.
Forums: A Gardeners Forum, Scouters World, and UGN Security
UBB.Threads: My UBB Themes, My UBB Scripts
Joined: Jan 2003
Posts: 3,456
Likes: 2
I
Master Hacker
Offline
Master Hacker
I
Joined: Jan 2003
Posts: 3,456
Likes: 2
Quote
Originally posted by Gizzy:

Thank god i didn't install it yet :x...

*laughs at the idea of Gizzy installing a mod* tipsy

Joined: Jan 2000
Posts: 5,819
Likes: 16
UBBDev / UBBWiki Owner
Time Lord
Offline
UBBDev / UBBWiki Owner
Time Lord
Joined: Jan 2000
Posts: 5,819
Likes: 16
hey; you're the one who asks me if you can install them to my board... Evidently UGN is Al's test board lol...

I don't even think my "mod's installed" post is accurate anymore; you should update the list lol...


UBB.Dev - Putting Dev into UBB.threads
Company: VNC Web Services - UBB.threads Scripts and Scripting, Install and Upgrade Services, Site and Server Maintenance.
Forums: A Gardeners Forum, Scouters World, and UGN Security
UBB.Threads: My UBB Themes, My UBB Scripts
Sponsored Links
Joined: Mar 2000
Posts: 21,079
Likes: 3
I type Like navaho
Offline
I type Like navaho
Joined: Mar 2000
Posts: 21,079
Likes: 3
I'm having a difficult time finding a couple pieces in ubb_search.cgi

In the instructions there's 3 sections to find in ubb_search.cgi, I can't find the last 2 smash


- Allen wavey
- What Drives You?
Joined: Nov 2001
Posts: 1,704
C
CTM Offline OP
Moderator / Da Masta
OP Offline
Moderator / Da Masta
C
Joined: Nov 2001
Posts: 1,704
Well that's weird, because I wrote the thing and I can't find those bits either... smash

Does the mod work okay without those instructions? If so, those instructions must've come from a previous mod that I based the documentation on. If PCRFs are searchable by authenticated users and are unsearchable by unauthorised users without the bits you can't find, then those instructions mean nothing and I need to remove them. I'll take another bash at this after the exam today.

Thanks for the report Allen smile

Joined: Mar 2004
Posts: 58
T
Member
Offline
Member
T
Joined: Mar 2004
Posts: 58
I added this mod but the number of posts I set in a forum doesn't stay saved and the restriction doesn't work

Joined: Nov 2001
Posts: 1,704
C
CTM Offline OP
Moderator / Da Masta
OP Offline
Moderator / Da Masta
C
Joined: Nov 2001
Posts: 1,704
A few people have told me that this works on 6.7.1, and as far as I know there haven't been any code changes that would affect this mod. Try rehacking ubb_lib.cgi, ubb_forum_summary.cgi, and especially cp2_forums.cgi.

Joined: Mar 2004
Posts: 58
T
Member
Offline
Member
T
Joined: Mar 2004
Posts: 58
I tried it 3 times and it's still the same

What should be the room settings of the one I want to restrict? does it have to be set as a Private Room? does the room name must be checked under the Forum Permissions in the user profile?

Joined: Sep 2005
Posts: 136
A
Journeyman
Offline
Journeyman
A
Joined: Sep 2005
Posts: 136
I'm having the same problem, its not sticking to the restricted number, I save it then go back in to see if its still there in the CP but it is not.

Joined: Nov 2001
Posts: 1,704
C
CTM Offline OP
Moderator / Da Masta
OP Offline
Moderator / Da Masta
C
Joined: Nov 2001
Posts: 1,704
Quote
Originally posted by AshtarRose:

I'm having the same problem, its not sticking to the restricted number, I save it then go back in to see if its still there in the CP but it is not.

Which version of UBB.classic are you using?

Joined: Sep 2005
Posts: 136
A
Journeyman
Offline
Journeyman
A
Joined: Sep 2005
Posts: 136
6.7.0

Joined: Sep 2005
Posts: 136
A
Journeyman
Offline
Journeyman
A
Joined: Sep 2005
Posts: 136
anyone trying to fix this?

Joined: Nov 2001
Posts: 1,704
C
CTM Offline OP
Moderator / Da Masta
OP Offline
Moderator / Da Masta
C
Joined: Nov 2001
Posts: 1,704
Are you using any other mods (particularly ones that involve forums or the Control Panel) alongside this one?

I'll see if I can install the mod on a fresh copy of 6.7.0 later tonight, and if not I'll mess with the code a bit to see what's wrong. smile

Joined: Sep 2005
Posts: 136
A
Journeyman
Offline
Journeyman
A
Joined: Sep 2005
Posts: 136
Edit User Name
Category Minimize
Modwordlets6
Restricted Post count (obviously)
ModCPaddon6
Strike System
Statitics6
HitHack6
Spell6
No Spam Replies
Removed Member #
Posts don't count


In that order is how I installed them

Joined: Sep 2005
Posts: 44
G
God Offline
Member
Offline
Member
G
Joined: Sep 2005
Posts: 44
I'm trying to do this for 6.6 and I can't find:

} # end MakeUBBERCookie

in ubb_lib.cgi

Joined: Mar 2001
Posts: 7,394
L
LK Offline
Admin / Code Breaker
Offline
Admin / Code Breaker
L
Joined: Mar 2001
Posts: 7,394
Add it to any end of a sub in ubb_lib, for example add it after:
Code
} # end RequireUserLogin

Joined: Sep 2005
Posts: 44
G
God Offline
Member
Offline
Member
G
Joined: Sep 2005
Posts: 44
Thanks..

I'm almost done installing this. Will this allow me to prevent users with a post count >25 from viewing and posting in certain areas or is it only for the search and recent viewers?

Joined: Sep 2005
Posts: 44
G
God Offline
Member
Offline
Member
G
Joined: Sep 2005
Posts: 44
Ok, I installed it and it seems that it does not work on 6.6... anyone think they could fix it or is 6.6 forgotten by all now?


I added a test forum and tried it with a test account and it didn't work. Now I can't delete the test forum for some reason. It gives me this error after I've deleted it and I try to access it.

Quote
quote:

An error has occurred:

No such file or directory opening NonCGIPath/Forum17 at CGIPath/ubb_lib_files.cgi line 878
main::NiceForumThreadsRebuild() called at CGIPath/ubb_lib_files.cgi line 436
main::GenerateDotThreadsFile() called at CGIPath/ubb_lib_files.cgi line 412
main::GetForumTopics() called at CGIPath/ubb_forum.cgi line 247
main::get_forum called at ultimatebb.cgi line 706

Please inform the board administration of this error so that they may fix the problem. Thank you!
I put all of the original files back and it still doesn't work.

Here's the debug info when I try to delete the testing forum for the second time.

quote:
[qb]Debug Information
StandardHTML stack trace:
at /home/s1xsan5/public_html/ubb/Templates//cp2_common.pl line 90 main::StandardHTML called at /home/s1xsan5/public_html/ubb/Templates//cp2_common.pl line 122 main::StandardHTML2() called at /home/s1xsan5/public_html/cgi-bin/cp2_lib.cgi line 739 main::CatchException() called at cp.cgi line 493 main::__ANON__() called at Modules/Error.pm line 303 eval {...} called at Modules/Error.pm line 294 Error::subs::run_clauses() called at Modules/Error.pm line 386 Error::subs::try() called at cp.cgi line 494
Extra information:

No such file or directory opening Forum17
Stack trace:
No such file or directory opening Forum17 at /home/s1xsan5/public_html/cgi-bin/cp2_forums.cgi line 309
main::cp2_page_forums_tab_delete called at /home/s1xsan5/public_html/cgi-bin/cp2_lib.cgi line 172
main::AutoHandle called at cp.cgi line 491
main::__ANON__() called at Modules/Error.pm line 368
eval {...} called at Modules/Error.pm line 367
Error::subs::try() called
[/qb]
Someone please help me out with this. My last complete backup is over two weeks old.

Joined: Aug 2000
Posts: 178
P
Member
Offline
Member
P
Joined: Aug 2000
Posts: 178
I sent CTM a PM this morning, but I can;t tell when the last time he was actually around. Is there anyway to get a copy of this? Dunno why I never grabbed it... I thought it was to create a forum that did'nt count posts I guess smile

If CTM or anyone can help me - [email protected]

Thanks!

Joined: Mar 2000
Posts: 21,079
Likes: 3
I type Like navaho
Offline
I type Like navaho
Joined: Mar 2000
Posts: 21,079
Likes: 3
You might give him until Monday or so to respond, some people access their accounts Mon-Fri.


- Allen wavey
- What Drives You?
Joined: Aug 2000
Posts: 178
P
Member
Offline
Member
P
Joined: Aug 2000
Posts: 178
No luck with contacting CTM. Anyone have it archived somewhere ? I really Really REALLY could use this modification.

Thanks,

Joined: Mar 2000
Posts: 21,079
Likes: 3
I type Like navaho
Offline
I type Like navaho
Joined: Mar 2000
Posts: 21,079
Likes: 3
I have stuff going back to 1999, but need to look for the 6.7.x series mods, they aren't on 2 of the archives I have here. I'll let you know if I find'em smile


- Allen wavey
- What Drives You?
Joined: Aug 2000
Posts: 178
P
Member
Offline
Member
P
Joined: Aug 2000
Posts: 178
Thanks! I'll check back every hour on the hour!!

Joined: Mar 2000
Posts: 21,079
Likes: 3
I type Like navaho
Offline
I type Like navaho
Joined: Mar 2000
Posts: 21,079
Likes: 3
wink

Give me until this weekend, we're getting the house appraised today and I've been swamped with work here there and everywhere. smile


- Allen wavey
- What Drives You?
Joined: Aug 2000
Posts: 178
P
Member
Offline
Member
P
Joined: Aug 2000
Posts: 178
Is it the weekend where you live too? smile

Hope your appraisel nets you more money or less taxes!


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
Posts: 70
Joined: January 2007
Forum Statistics
Forums63
Topics37,558
Posts293,857
Members13,848
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,819
Greg Hard 4,625
Top Posters(30 Days)
Top Likes Received
isaac 70
Gizmo 16
Brett 7
WebGuy 2
Morgan 2
Top Likes Received (30 Days)
None yet
The UBB.Developers Network (UBB.Dev/Threads.Dev) is ©2000-2022 VNC Web Services

 
Powered by UBB.threads™ PHP Forum Software 8.0.0
(Snapshot build 20220106)
Responsive Width:

PHP: 7.3.29 Page Time: 0.025s Queries: 79 (0.008s) Memory: 0.9579 MB (Peak: 1.1041 MB) Data Comp: Zlib Server Time: 2022-01-21 08:10:51 UTC
Valid HTML 5 and Valid CSS