The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
Going to write a hack...
Probably just for use at my own board but who knows, if it turns out good i may release here.
Basically, i'm looking to create a section of my site that only register members of certain user groups can access. It's not a forum, but actually website (of sorts) with files and other extras that members of the forum will be able to access (no one else). Just wondered if anyone could help me get started and offer any tips. If someone tries to access the section of the site i'd like it to check if they are logged in, and then to decided what to do based on their user group. If they are not, it'll post the login code. I'm guessing all i need to do is add this at the begining of my php file and it will check the rest? require('./global.php'); if ($bbuserinfo['userid']=0) { // Some sort of login code here } is that an okay start and am i on the right track? I wanted to more or less integrated with vb, but my concern is that by using the above code when people access the website section it will update when they last visited the forum (even though it's not a visit). Hope i made sense somewhere in there |
#2
|
|||
|
|||
If global.php is included, I believe it WILL update their last visit, but i'm not 100% sure on that.
|
#3
|
||||
|
||||
Something like this should get you started...
(If the page isn't in your forums directory, you will need this first chdir line. If not then it's not necessary ) PHP Code:
|
#4
|
|||
|
|||
Thanks very much for the information
It's a great start and after looking over my idea for the site i agree that it would be better for the last visit and WOL list to be updated so the code you listed is perfect Thanks again, ~Rad |
#5
|
||||
|
||||
No problem.
One thing though - Take the trailing slash off the end in that code. Just looked at it again and noticed that was there. |
#6
|
|||
|
|||
Thanks again
I've already got around 90% of the hack done but i might re-write part of it so it actually uses a database It's easier to integrate things into vb than i thought it would be ! |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|