![]() |
|
Mod Options |
![]() |
|||||||||||
Simple vB User login and access control on non vB pages
![]() Developer Last Online: Nov 2011 ![]() ![]() ![]() This modification is in the archives.
Hack Description
This is a cutdown version of the user authentication and access control system I use on the non vB pages on my website. This uses the vB 3.5 login system to log you in and out. It allows you to move between your forums and other pages on your site while remaining logged in. It allows you to do things such as restrict pages by usergroup, display different content depending on a user being logged in or not. For example, you can have banner Adds displying to non members only, and/or let members access to specific content. Ive cut it down to the bare minimum that it needs to work, no fancy stuff such as avatars, PM's, or even formating. I will try and offer support, but work and family commitments mean I dont have much free time. This code is a mix of my own, and pieces I have used from other hacks that are floating around. This script has been confirmed as working on
Changelog Version 1.30 (24th April 2007)
Version 1.20 (2nd December 2006)
Version 1.10 (4th Feb 2006)
There is no functionality changes or bug fixes between these 2 releases. Version 1.0 (17th November 2005)
Deluxe Version of this hack is now available Has Avatars, PM's, Number of Posts etc. Click Here Click on Install If you have this script installed then please click on the install link because;
Donations First of all, to be clear. This script is 100% free. However if you feel an urge to donate I'm not going to say no. ![]() Donations can be made at http://www.billspaintball.com/vb3/bd_donate.php Download Now Only licensed members can download files, Click Here for more information. Show Your Support
No members have liked this post.
|
![]() |
||||
Mod | Developer | Type | Replies | Last Post |
Integration with vBulletin Simple vB User login and access control on non vB pages | Billspaintball | vBulletin 3.6 Add-ons | 188 | 25 Jan 2013 16:40 |
Deluxe vB User login and access control on non vB pages | Billspaintball | vBulletin 3.5 Add-ons | 393 | 13 Jul 2011 21:50 |
Integration with vBulletin Deluxe vB User login and access control on non vB pages | Billspaintball | vBulletin 3.7 Add-ons | 76 | 06 Jun 2011 21:44 |
Integration with vBulletin Simple vB User login and access control on non vB pages | Billspaintball | vBulletin 3.7 Add-ons | 55 | 23 Apr 2011 14:52 |
Integration with vBulletin Deluxe vB user login and access control for non vB pages - REVISED | Mastar | vBulletin 3.6 Add-ons | 12 | 15 May 2009 16:17 |
Comments |
#2
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Edit: This usage and trouble shooting guide has been updated as of 24th of April 2007
Usage The hack is pretty useless without some usage instructions so here they are. We can use conditionals to hide or display depending on a number of things such as Logged in or out status, or restrict to members of a specific usergroup. We do this by using conditionals in php tags where the normal content of a webpage would go. If you want something only accessable to a certain usergroup, use this code in your webpage. This example is only visible to members of usergroup 6.
You can use a simple variation of this to restrict entire pages to a certain usergroup. For example,
You can of course use multiple usergroups by just modifiying the if statement a little. For example:
Another use is to display different content to users depending on if they are logged in or not. For example
Another use is to restrict advertising to people who are not logged in. For example
Of course you can play around with conditionals to do a whole range of things, these are just brief example snippets. Troubleshooting If your reading this chances are you are having problems. Here are some common causes and fixes.
No members have liked this post.
Last edited by Billspaintball; 24 Apr 2007 at 15:49. |
#3
|
|||
|
|||
Thanks, I'll test it out!
No members have liked this post.
|
#4
|
|||
|
|||
I know this is proabably a dumb question, but I am not technical. Does the basic web page have to be set up as a .php page or can this be used in an html page?
No members have liked this post.
|
#5
|
||||
|
||||
Originally Posted by iankh
Yes the webpage must be a php page else it wont work.
You can of course have HTML and PHP mixed on the same .php page, PHP is only parsed if its inside the <?php ?> tags. Outside of these, normal HTML will work as normal. No members have liked this post.
|
#6
|
||||
|
||||
Great work!
No members have liked this post.
|
#7
|
|||
|
|||
Great work, thanks you.
No members have liked this post.
|
#8
|
|||
|
|||
hmmm why do i get
Warning: chdir(): No such file or directory (errno 2) in /home/site/public_html/site/index.php on line 2 i've entered the path to the forums, full url and just /forums/ but still same error No members have liked this post.
|
#9
|
||||
|
||||
Originally Posted by reeps
Edited:
Thats the same error message I get if I change the path to my forums so that its incorrect. Double check the path to your forums. Edited again: I've added information to the opening post on how to find the correct path to your forums. No members have liked this post.
Last edited by Billspaintball; 23 Nov 2005 at 22:16. |
#10
|
|||
|
|||
ok after i login it brings me back to the login page with the form. isn't it supposed to recognize you're logged in?
No members have liked this post.
Last edited by MOREAGA; 19 Nov 2005 at 01:52. |
#11
|
||||
|
||||
Yes it is supposed to recognise when your logged in or out.
See these 2 pics to see what it should show when you are logged in or out. I would suspect it may be a cookie / cached files / browser security issue. In you browser settings, try deleting temp internet files and cookies. No members have liked this post.
Last edited by Billspaintball; 19 Nov 2005 at 05:07. |
#12
|
|||
|
|||
i think it's because i use my domain for my site, and a sub domain for my forums, that's the feedback everyone keeps telling me, any way around this problem? besides and iframe.
No members have liked this post.
|
#13
|
||||
|
||||
got a little java-error in there... any ideas? script runs fine so there is missing a "(" on line 9 (read via right-mouse-click) while showing login-form... yellow sign left bottom... error... page shows up correctly but an java-error occured in the background...
No members have liked this post.
|
#14
|
||||
|
||||
Originally Posted by MOREAGA
Ive read about other scripts having this issue if one of them was in a diffrent subdomain.
Im not sure if they ever found a solution, but I will look. No members have liked this post.
|
#15
|
||||
|
||||
![]()
Originally Posted by iankh
If you want PHP to work in your .html pages, and if you are on apache server you can make your server to parse php scripts in your html files. Insert this code in your .htaccess file, to make php work in .html files:
A demo of this parsing is here: http://www.photoshopcity.com/content...ml?parent_id=7. See those ?parent_id vars... ![]() No members have liked this post.
|
![]() |
«
Previous Mod
|
Next Mod
»
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Mod Options | |
|
|
New To Site? | Need Help? |
All times are GMT. The time now is 15:49.