Register Members List Search Today's Posts Mark Forums Read

Reply
 
Mod Options
Simple vB User login and access control on non vB pages Details »
Simple vB User login and access control on non vB pages
Mod Version: 1.30, by Billspaintball (Member) Billspaintball is offline
Developer Last Online: Nov 2011 I like it Show Printable Version Email this Page

This modification is in the archives.
vB Version: 3.5.8 Rating: (4 votes - 5.00 average) Installs: 138
Released: 17 Nov 2005 Last Update: 24 Apr 2007 Downloads: 979
Not Supported Additional Files  

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
  • vB 3.5.x - All Versions


Changelog

Version 1.30 (24th April 2007)
  • Fixed - // in paths bug
  • Fixed - Javascript warning in some browsers
  • Fixed - Tidied up some code

Version 1.20 (2nd December 2006)
  • Fixed Logout incorrect path bug
  • Made change to reduce compatibility problems with foreign scripts

Version 1.10 (4th Feb 2006)
  • Changed login_inc.php so you only need to edit path in one place now.
  • Added more commenting to login_inc.php
  • Added usage instructions to instructions file
  • Added troubleshooting guide with all common problems and fixes to instructions file.
Note: It is NOT necessary to update from 1.0 to 1.10.
There is no functionality changes or bug fixes between these 2 releases.

Version 1.0 (17th November 2005)
  • Initial Release


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;
  • You will get notified if any security issues are reported.
  • You will get notified when there are any upgrades to this script
  • It gives me a warm fuzzy feeling and motivates me to develop more

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

  • To receive notifications regarding updates -> Click to Mark as Installed.
  • If you like this modification support the author by donating.
  • This modification may not be copied, reproduced or published elsewhere without author's permission.
Similar Mod
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

  #151  
Old 10 Jun 2006, 04:32
Billspaintball's Avatar
Billspaintball Billspaintball is offline
 
Join Date: Sep 2003
Real name: Bill
Ok, try this.
Right at the top of the page put

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

and put the login box where ever with

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

let us know if this works, If not, I will need the exact error message before I can look any further.
Reply With Quote
  #152  
Old 10 Jun 2006, 10:42
Munnday Munnday is offline
 
Join Date: Jul 2002
I receive the following error:
Warning: array_keys(): The first argument should be an array in /includes/functions.php on line 3277

Warning: Invalid argument supplied for foreach() in /includes/functions.php on line 3277

Fatal error: Call to a member function on a non-object in /home/.katona/wisemonkeys/www.4wisemonkeys.com/community/includes/functions.php on line 2502
Reply With Quote
  #153  
Old 14 Jun 2006, 03:25
evenmonkeys's Avatar
evenmonkeys evenmonkeys is offline
 
Join Date: Aug 2004
Location: Iowa
Real name: Austin
I am not able to run this and I have gone through the troubleshooting steps that you have provided. I am running my main site on http://website.com and I am running my forum on http://forums.website.com. I've tried using website.com/forums as well, but that is not working either. Other than the steps you have provided, do you have any other recommendations?

The reason I'm still curious is because I had the vBadvanced CMPS working on my website before, and I had it set up the exact same way. However, I am unable to figure out what made what tick. Let me know please.
Reply With Quote
  #154  
Old 14 Jun 2006, 09:12
nonstop nonstop is offline
 
Join Date: Jun 2006
Originally Posted by Yarub
I am not able to run this and I have gone through the troubleshooting steps that you have provided. I am running my main site on http://website.com and I am running my forum on http://forums.website.com. I've tried using website.com/forums as well, but that is not working either. Other than the steps you have provided, do you have any other recommendations?

The reason I'm still curious is because I had the vBadvanced CMPS working on my website before, and I had it set up the exact same way. However, I am unable to figure out what made what tick. Let me know please.
I would suggest looking at the error log file for the site in question and see if it gives some errors to point were the problem. I had a similar problem as I just recently setup the forums on something like forum.mydomain.com and the site with the loging on www.mydomain.com (these are examples). Since the location of the files for each of these domains are in totally different directory structures the php configuration open_basedir refused to all the include for security reasons (value open_basedir was set to null which means that I can include anything below the directoy of the script calling). Not sure if this may be your problem with the installation with the forums in a separate directory or not. Its all based on physical file location. If this is the problem you might have the option of having your admin set the open_basedir configuration specific to your domain such that you can include the files needed from the forums. Here is the link on php site relating to the open_basedir http://us2.php.net/features.safe-mode. Hope this helps.
Reply With Quote
  #155  
Old 15 Jun 2006, 17:18
s.blair s.blair is offline
 
Join Date: Jan 2006
Great looking hack!

I've got the basics of it working on my site.

However I need to control access based on secondary 'additional' user groups rather than the primary usergroup id.

How can I have it check to see if the user is in the array of membergroup id's instead of a single usergroup?

Thanks.
Scott
Reply With Quote
  #156  
Old 17 Jun 2006, 15:11
Majava's Avatar
Majava Majava is offline
 
Join Date: Jun 2006
Real name: Nick
Hi, i need help please.. i added the login box on the index page, works great. but when i try and access the other pages. i get the following error.


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

I think its because my index page includes other files from /includes/ for the other pages. so basically everything is run through the index page. If you want to view it go here. www.silkroad-oasis.com.


also, if you go to http://www.silkroad-oasis.com and login on the box, it logs in and works fine, but if you go to http://silkroad-oasis.com and try and login, it logs you in, but still shows the login boxes. how to fix?

Please help. Thanks

Last edited by Majava; 17 Jun 2006 at 17:41.
Reply With Quote
  #157  
Old 19 Jun 2006, 11:27
Billspaintball's Avatar
Billspaintball Billspaintball is offline
 
Join Date: Sep 2003
Real name: Bill
Originally Posted by Majava
I think its because my index page includes other files from /includes/ for the other pages. so basically everything is run through the index page. If you want to view it go here. www.silkroad-oasis.com.


also, if you go to http://www.silkroad-oasis.com and login on the box, it logs in and works fine, but if you go to http://silkroad-oasis.com and try and login, it logs you in, but still shows the login boxes. how to fix?

Please help. Thanks
Have you tried steps 3 and 4 in the troubleshooting guide yet?
Reply With Quote
  #158  
Old 20 Jun 2006, 17:04
Majava's Avatar
Majava Majava is offline
 
Join Date: Jun 2006
Real name: Nick
Originally Posted by Billspaintball
Have you tried steps 3 and 4 in the troubleshooting guide yet?

ok, Step 3 had already been done. by default? i dont know.

I dont both things in step 4, but still i get the following errors on every other page, but it did sort out the login box problem,


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

my index file is used as the main page.. when someone clicks a new page on the site the index file finds the included file and uses it. eg. index.php ---> index.php?page=status

Is there anyway to fix this warning?
Reply With Quote
  #159  
Old 21 Jun 2006, 00:07
Billspaintball's Avatar
Billspaintball Billspaintball is offline
 
Join Date: Sep 2003
Real name: Bill
Originally Posted by Majava
ok, Step 3 had already been done. by default? i dont know.

I dont both things in step 4, but still i get the following errors on every other page, but it did sort out the login box problem,
Yes, those steps in the troubleshooting guide will only fix the login box, not your other path problems, its two seperate issues.

Is there anyway to fix this warning?
It looks like its a path problem, could well be caused because the path is set to your forums directory for global.php.
Try changing

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

to

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.


Last edited by Billspaintball; 21 Jun 2006 at 00:10.
Reply With Quote
  #160  
Old 21 Jun 2006, 09:46
Majava's Avatar
Majava Majava is offline
 
Join Date: Jun 2006
Real name: Nick
Nope, still same error.

Do i need to put that still in everypage? or just the index page?

and if you need me to, i can post the index page php code.
Reply With Quote
  #161  
Old 22 Jun 2006, 06:11
Billspaintball's Avatar
Billspaintball Billspaintball is offline
 
Join Date: Sep 2003
Real name: Bill
Originally Posted by Majava
Do i need to put that still in everypage? or just the index page?
.
If everything is just included into the index page thats the only spot you would need to put it.

You can post the index page code if you like and I will have a look for anything obvious.
Reply With Quote
  #162  
Old 22 Jun 2006, 09:58
Majava's Avatar
Majava Majava is offline
 
Join Date: Jun 2006
Real name: Nick
This is at the top

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

This is my main code
Reply With Quote
  #163  
Old 23 Jun 2006, 04:14
Billspaintball's Avatar
Billspaintball Billspaintball is offline
 
Join Date: Sep 2003
Real name: Bill
[QUOTE=Majava]This is at the top

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Try something like


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

If that fails to work then it looks like both scripts are just incompatible
Reply With Quote
  #164  
Old 24 Jun 2006, 10:07
Dark s.s. Trunk's Avatar
Dark s.s. Trunk Dark s.s. Trunk is offline
 
Join Date: Apr 2004
Location: Good Guestion its dark
Real name: Kristopher... at least it
I have a strange problem lol i seem to be permittly logged in. Now on my forums when i log off and go to main forum page it shows me as logged in, and on the page i put the code i hit log out goes to forums cookies cleared aand all but when it goes back to page still logged in,, even cleared IE cashe and still does it
----------------
Edit: that problem was bad cashe in IE but now ran into another problem, i have 2 php files i use one has a bit different b/c of the way i display some pages but works perfect on mainpage.php but any file that seems to use my mainpage2.php it goes to log in but keeps telling me to log in but still logged in on mainpage.php.. all ode for login exact same.

Note seems pages dun work on anything linked to in the address bar like thsi http://twistedeffects.com/mainpage.p...iles/tutorials
__________________
Favorite Hacks:
-RPG Integration Hack v2.5.3
-VbDownloads 2.0

Quotes:
"I do not suffer from insanity, I enjoy every minute of it"
"Consciousness - that annoying time between naps!"
"your just jealous becuase the voices only talk to me"

Last edited by Dark s.s. Trunk; 24 Jun 2006 at 10:52.
Reply With Quote
  #165  
Old 25 Jun 2006, 11:28
hurry hurry is offline
 
Join Date: Feb 2006
It still does not work for me

Originally Posted by AutoXer
I fixed it. Here's how:

AdminCP -> vBulletin Options -> Cookies and HTTP Header Options -> Path to Save Cookies

I changed the 'Suggested Settings' dropdown from '/forums/' to '/'
I did this but it still does not work for me and gives me the forum logged in screen and then again returns back to the page without being logged in. Please help.
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Mod Options

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


New To Site? Need Help?

All times are GMT. The time now is 04:24.

Layout Options | Width: Wide Color: