Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - Restricting Access
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Restricting Access

 Post Reply Post Reply Page  12>
Author
snatchby View Drop Down
Newbie
Newbie


Joined: 02 April 2003
Status: Offline
Points: 12
Post Options Post Options   Thanks (0) Thanks(0)   Quote snatchby Quote  Post ReplyReply Direct Link To This Post Topic: Restricting Access
    Posted: 03 April 2003 at 12:42am

is there a way to use this script to restrict other pages on the web site using the same login info?

thanks

Back to Top
dj air View Drop Down
Senior Member
Senior Member
Avatar

Joined: 05 April 2002
Location: United Kingdom
Status: Offline
Points: 3627
Post Options Post Options   Thanks (0) Thanks(0)   Quote dj air Quote  Post ReplyReply Direct Link To This Post Posted: 03 April 2003 at 1:50am

what version are you useing.... 6.34 or V7

this is for v7

ive implimented this feature on my site (members area)... what you need to do is add the common.asp to each page you want to restrict (make sure you make the paths in the common.asp file to virtual (use / )....

then include it in your page ... and then if you dont want to stop guest accessing the page

add this code below the common.asp file

if blnGuest = True then response.redirect "/forum/insafficiant_permissions.asp"

if you want the admin to only access this page use

if NOT blnAdmin = True then response.redirect "/forum/insafficiant_permissions.asp"

use the same for moderators exceopt change it to blnModerator

 

for v6.34 download this zip which had the permissions and common.asp and a read me file about it

zip file

Back to Top
snatchby View Drop Down
Newbie
Newbie


Joined: 02 April 2003
Status: Offline
Points: 12
Post Options Post Options   Thanks (0) Thanks(0)   Quote snatchby Quote  Post ReplyReply Direct Link To This Post Posted: 03 April 2003 at 3:55pm

so i copy the content from the common.asp to the top of the pages i want restricted??

Back to Top
dj air View Drop Down
Senior Member
Senior Member
Avatar

Joined: 05 April 2002
Location: United Kingdom
Status: Offline
Points: 3627
Post Options Post Options   Thanks (0) Thanks(0)   Quote dj air Quote  Post ReplyReply Direct Link To This Post Posted: 04 April 2003 at 8:37am

yes but also add one of the following

if blnGuest = True then response.redirect "/forum/insafficiant_permissions.asp"

if you want the admin to only access this page use

if NOT blnAdmin = True then response.redirect "/forum/insafficiant_permissions.asp"

use the same for moderators exceopt change it to blnModerator

thats for must be a admin , moderator or guest .... also dont forget to make the paths to the include files virtual ie /frorum/

Back to Top
xeerex View Drop Down
Senior Member
Senior Member


Joined: 19 November 2002
Location: United States
Status: Offline
Points: 601
Post Options Post Options   Thanks (0) Thanks(0)   Quote xeerex Quote  Post ReplyReply Direct Link To This Post Posted: 04 April 2003 at 5:28pm

You don't have to copy all the content from common.asp. Just have it as on include on the page you want to restrict. Then add the "if statements" that DJ indicated above.

With DJ's help, I was able to implement this with v6.34 easily on one of my sites. The security for v7 should basically be the same just more groups to deal with if you make more than the default groups.

Back to Top
fernan82 View Drop Down
Mod Builder Group
Mod Builder Group
Avatar

Joined: 17 November 2002
Location: United States
Status: Offline
Points: 362
Post Options Post Options   Thanks (0) Thanks(0)   Quote fernan82 Quote  Post ReplyReply Direct Link To This Post Posted: 04 April 2003 at 7:17pm
or you can use this mod i made. It's basically the same as the common.asp, only i removed most of the code that's not needed so it won't affect performace much and also won't update the last date you visit the forum by just visiting a page on your site as it would if you just include the common.asp on every page.... also i've set it so you'll only have to edit which groups you want to be able to access the page and edit your db info.....read the readme file if you're gonna use it...
FeRnAN
Back to Top
snatchby View Drop Down
Newbie
Newbie


Joined: 02 April 2003
Status: Offline
Points: 12
Post Options Post Options   Thanks (0) Thanks(0)   Quote snatchby Quote  Post ReplyReply Direct Link To This Post Posted: 05 April 2003 at 10:57am

hey xeerex do you mind terribly telling me the exact line to put in and which file to put it in and where to put it in....thanks - cuz i dont know ASP.

Back to Top
snatchby View Drop Down
Newbie
Newbie


Joined: 02 April 2003
Status: Offline
Points: 12
Post Options Post Options   Thanks (0) Thanks(0)   Quote snatchby Quote  Post ReplyReply Direct Link To This Post Posted: 06 April 2003 at 3:34am
do all the pages i want restricted have to be ASP also??
Back to Top
 Post Reply Post Reply Page  12>

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.08
Copyright ©2001-2026 Web Wiz Ltd.


Become a Fan on Facebook Follow us on X Connect with us on LinkedIn Web Wiz Blogs
About Web Wiz | Contact Web Wiz | Terms & Conditions | Cookies | Privacy Notice

Web Wiz is the trading name of Web Wiz Ltd. Company registration No. 05977755. Registered in England and Wales.
Registered office: Web Wiz Ltd, Unit 18, The Glenmore Centre, Fancy Road, Poole, Dorset, BH12 4FB, UK.

Prices exclude VAT at 20% unless otherwise stated. VAT No. GB988999105 - $, € prices shown as a guideline only.

Copyright ©2001-2026 Web Wiz Ltd. All rights reserved.