vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.0 Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=33)
-   -   Dorm Manager System (https://vborg.vbsupport.ru/showthread.php?t=66161)

Darkwaltz4 12-28-2004 04:18 AM

oh, a quick and dirty hack you could do yourself if i dont come through for you~

find in dorms.php...
PHP Code:

if(!$bbuserinfo[userid]) print_no_permission(); 

now, usergroups have certain id numbers, which you can find by hovering links in the acp usergroup screen. so if you want to restrict it to certain groups, find the number (ill call it X for my example) then edit that line to be...

PHP Code:

if(!$bbuserinfo[userid] and $bbuserinfo[usergroupid]!=Xprint_no_permission(); 

this will restrict the page from being accessed by any usergroup that isnt X (which i assume would be your subscrber group, or any existing one you might want) also, you can allow more than one, by just finding out the extra groups' numbers (Y and Z for the example) and adding more and etc's to the code...

PHP Code:

if(!$bbuserinfo[userid] and $bbuserinfo[usergroupid]!=and $bbuserinfo[usergroupid]!=and $bbuserinfo[usergroupid]!=Zprint_no_permission(); 

this isnt confusing is it? like i said, this is the less elegant way to get what you want in case i cant find time to do it elegantly :-p

docvader 12-28-2004 05:36 AM

Thanks DW. Your support of this hack is unsurpassed and greatly appreciated.

I still have some troubles. Got it to work again, reinstalled php file and templates (I had altered the templates a little), and now it's sending PM's and allowing the opening of threads. However, my registered users, who I accept into the dorm, cannot access it. Get the usual "you have no permission" error.

I'm baffled. Any suggestions???

rich

Darkwaltz4 12-28-2004 05:40 AM

what are your global dorm settings, and parent forum settings?
do you mean they cant access the panel, the dorm forum they belong to, or the threads that were created in the dorm forum?

docvader 12-28-2004 06:02 AM

OK DW, you da man. I had the parent forum as one of my older restricted forums, and the permissions setup was keeping people out. I trashed it, and created a new parent forum. I figured out a few things, which I'd like to share with you all, in case you're trying to do this. I think this works. DW no doubt will have more and better suggestions.

I made a link to the dorms.php in my navigation bar. That is the only entrance to the dorms. I think, for this to work, you have to make members try to enter via your http://www.site.com/forums/dorms.php link. If they try to access through threads on your forum index page, in some cases, they will be able to view what's going on.

I made a parent forum in vb, which you can call whatever you want. I made mine as follows:
act as a forum: no
forum is active: no
forum is open: no
index posts in search: no
no password


I found that if you make it active, ie, visible, people can access it via the forum index page, where they can see the forum. (I tried to make that link the forum/dorms.php link, but was unsuccessful in doing so; my ignorance as to how to do that properly I guess).

This way, it's not visible. People don't know it even exists, unless they enter through the navigation bar link. The nav bar link brings them to DW's dorms area, where the dorm figures out access. People can't bypass and enter the area, because the dorm php takes care of all access.

So far, so good.

Thanks
rich
x.russbo.com/index.php

docvader 12-28-2004 02:05 PM

OK, the above keeps it from being seen on the forum index, and keeps non dorm members out, but anybody who clicks on "New Posts" or some sort of "Posts from one, two, etc days ago" can see the dorm threads pop up, and read them. That's the issue. How do we get around that? I'm keeping forum and child forum off of the forum jump menu also. Can't seem to figure out how to keep it from showing up on any sort of forum search.

I see Boxingscene in post 77 has the same issue.

Thanks!
rich
http://x.russbo.com/vb/index.php

docvader 12-29-2004 03:15 AM

OK, easy fix, which is why it took me a few hours to figure out.

I made the parent forum "active" so that it is visible on the forum index page. It will show the various dorms underneath it.
If you alter permissions for that parent forum, and set everything to "No" for all usergroups (except for your main admin, user id 1), when people do a search query, the parent forum, and the various dorms underneath, will not show up in any search (new posts, last day posts, two week posts, etc).

Accepted dorm members can access the dorm area via the dorms.php link, where ever you may have placed it.

Love this hack.
rich

docvader 12-29-2004 03:39 AM

Aargh. Again. That didn't do it. Keep looking...

docvader 12-29-2004 03:58 AM

Think this works.

I made the parent forum inactive so that it doesn't show.
I made the permissions for registered users so that they can post in the parent forum, but cannot search.

If the parent forum is active and visible, registered users will be able to see it and enter through forum index, but not through the dorms.php link. So, I made it invisible.
Turning "search forum" in the permissions off, for the parent forum, keeps registered users from searching in the "new posts, etc" search.php query.

Also, I used this hack, even though the above seemed to do the trick: https://vborg.vbsupport.ru/showthrea...exclude+forums

Confused? So am I. But, we're testing this now, this seems to do the job.

rich

Darkwaltz4 12-29-2004 05:27 AM

hehe, i really hate seeing all that you went through today, and i wasnt online at all to help out during it >.< but i think that one of the features i was planning would have taken care of exactly what you were trying to do :-p

utilizing the password system would i think be something like this...
------------------------------------------------------
admin options: allow password use/require password use (y/n)

dorm leader then can create a password for dorm which will be put un-md5'd into the dorm table (ull see why in a sec) upon creation of dorm, then setting the password into the forum system as normal. then pming the leader a backup copy of the password for himself.

subsequent members then get pmed a copy of the password upon acceptance, and the leader can change the password when he likes, which then sends an update pm to existing members, etc.

the password system then works like any other passworded forum, as the dorm hack would only use the password system as a wrapper (much like everything else :-p) thus....disabling vieiwing of contents/updates from non-members (those with the set password, on top of posting access with the dorm hack itself). oh, and also the proper authorities of course bypass the passwording to allow for moderation, but this is a standard vb feature of passworded forums :-p (which also works to advantage)

now keep in mind this is just me thinking out loud for right now, but if you think its great ill work on that :-p

docvader 12-29-2004 12:15 PM

Quote:

Originally Posted by Darkwaltz4
hehe, i really hate seeing all that you went through today, and i wasnt online at all to help out during it >.< but i think that one of the features i was planning would have taken care of exactly what you were trying to do :-p

utilizing the password system would i think be something like this...
------------------------------------------------------
admin options: allow password use/require password use (y/n)

dorm leader then can create a password for dorm which will be put un-md5'd into the dorm table (ull see why in a sec) upon creation of dorm, then setting the password into the forum system as normal. then pming the leader a backup copy of the password for himself.

subsequent members then get pmed a copy of the password upon acceptance, and the leader can change the password when he likes, which then sends an update pm to existing members, etc.

the password system then works like any other passworded forum, as the dorm hack would only use the password system as a wrapper (much like everything else :-p) thus....disabling vieiwing of contents/updates from non-members (those with the set password, on top of posting access with the dorm hack itself). oh, and also the proper authorities of course bypass the passwording to allow for moderation, but this is a standard vb feature of passworded forums :-p (which also works to advantage)

now keep in mind this is just me thinking out loud for right now, but if you think its great ill work on that :-p

Great idea. If you've got the time, I'd use it. But, to keep your life simpler, which is always a nice thing to do, is there anyway of keeping the new posts in the dorms off off the search.php? There is a simple &exclude command that you can keep in the navbar search link, to exclude search of some forums, but the problem is, the dorm keeps creating new forum numbers. So, that's a difficult option to implement. (Which is why I went the route I did; my above suggestions works, by the way).


All times are GMT. The time now is 09:21 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.02928 seconds
  • Memory Usage 1,764KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (3)bbcode_php_printable
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.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/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete