![]() |
Permissions: Can list posts, but not view.
What's up people!
I've been thinking of developing a hack, but my proficiency with vB is not all that great yet. So, I'll suggest this hack to you. Right now I have about 15 forums divided into 3 catagories on my page. Currently unregistered users cannot view anything, when they try to load a page, they are denied with a custom 'no permissions' message. When I allow them access to view some of the forums, the forums that they can't view dont even show up, and thus they are unaware of them, and have no compelling reason to register to be able to view them. So, I allow them access to view the forums, but not the posts. Then, it just looks to them as if all the posts have been removed - again, no motivation. The next step would be to allow them to view the posts, and thus negating the reason why I require registration. (It's mature content, you see.) So, if there were a happy medium in permissions, where users from a certain usergroup could LIST the thread topics, but not display the threads themselves, that would make things much more productive for the forum in question, while not completely denying access to all the other interesting, yet decidedly less private forums. Tell me what you think. :) |
Sounds like a good idea...
Satan |
Anyone willing to give it a shot?
|
edit showthread.php, find:
PHP Code:
PHP Code:
Create a new template named "error_youdonthavepermission" and specify your custom message for no permission.. (Dont forget to enable their permissions in Admin CP) If you want to apply the hack to 2 usergroups, change: PHP Code:
PHP Code:
|
Thank you very much :) :)
That gives me a little to work on.. perhaps add some DB integration and a front end. |
Logician
Is there a way for this to work for a thread instead of the forum & group ? I want them to view everything except the thread(post) |
Quote:
|
Don?t work by me
In the ACP i set the "View other Threads" for Unreg User on yes. Than i insert the code in showthread.php but the guest can see all :beard: any idea? PHP Code:
|
try to add your code after this part:
PHP Code:
|
Hmm nothing seems to work.
PHP Code:
A quick question If i want to restriuct access to 2 or 3 user groups would I jsut do this if ($forumid==X AND $bbuserinfo[usergroupid]==Y OR $bbuserinfo[usergroupid]==Z) |
I edited my code, please reapply. Your other question also has been answered above..
|
Thanks a million!
One last question: Woud this work as well? PHP Code:
Thank again for all you help!! :laugh: |
Quote:
PHP Code:
|
Works like a charm! Thanks again!
BTW Logician you should write this up as a hack and post it in the hafcks sections I bet many people would enjoy it! I know I do! Thanks!! |
Hello logi
Thanks now it work fine. But. I have over 200 Forumids :) Can i set a wildcard ? Thanks |
Quote:
PHP Code:
|
Thank you
Yes thats great |
I have this hack installed, and it works, but not exactly as I'd like.
Namely: When an unregistered visitor tries to open the thread, they're blocked, and must go through the registration process. That part's OK. However, they do not have to go through the confirmation process -- so, I get a fair number of registrations everyday from anyname@anydomain.com (and lots of variations). Can this hack be tweaked to force new registrants to respond to vB's email confirmation before they're allowed to open/view threads? |
Quote:
|
It was already set that way -- permissions for "Unregistered / Not Logged In" and "Users Awaiting Email Confirmation" are the same.
To be clear: I want to let anyone, registered or not, open up any of 11 different forums, and see all the titles of all the threads in that forum. However, only registered and confirmed people should be able to open a thread to view the posts within it. This is what I'm currently unable to do. I.e., I can force them to register before opening a thread, but I can't figure out how to force them to confirm before opening a thread. Within vB, I have the admin choice to set "view threads" -- which means really means, view all contents of threads. I need two on/off levels: "view thread titles" and "view thread contents." Btw, in the admin panel I can go to --> User Groups | Forum Permissions to do this, or to --> Forums & Moderators | Permissions -- and it's the same result, right? |
I'm sticking with my previous reply. :)
This is not related to the hack itself unless applied the hack wrongly in the first place. This line: PHP Code:
If your code is correct, your problem should be related to your forum permissions somehow. Quote:
|
Where can I find that line of code so that I can check it?
|
PHP Code:
What is the usergroupid? Would I insert "Unregistered / Not Logged In" as "usergroupid"? And is this compatible with 2.3.2? |
For "Unregistered / Not Logged In" its 1.
ie: PHP Code:
|
Is there an update for this hack for version 2.3.3? I noticed the code in the file is slightly different, and there are 2 occurences. I tried it anyway and nothing happened.
|
I did get this to work finally, you have to edit the second occurence in showthread.php, not the first.
|
All times are GMT. The time now is 04:49 AM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|