View Full Version : Password Scripts
Deland02
January 5th, 2005, 04:56 PM
Can anyone offer any advice on password scripts and how they work?
I want to password specific folders on my site so I can upload files into a folder and it will only be accessible with the correct username / password. I'd then give user’s details to access this folder.
Also if possible depending on the username / password entered, users would only be able to see or access certain files.
I have CGI/Perl Script enabled on my web space.
Can anyone point me in the right direction?
Digitalosophy
January 5th, 2005, 05:02 PM
Make your life easier and use htaccess :)
Run a search on google/and/or the forums.
Deland02
January 5th, 2005, 06:55 PM
Dont you have to be using LINUX servers for htaccess??
Hans Kilian
January 5th, 2005, 07:07 PM
No. You have to be using Apache as your web server. It runs fine under Windows too.
If you're using IIS then you have to set up the access definitions through some of MS's loooovely dialogs. Or at least that was how it was done a few years back when I last was responsible for a Windows server. God, I hate those dialogs :)
Deland02
January 6th, 2005, 08:21 AM
So Im gonna have to find out if my host has Apache installed?
Yeldarb
January 6th, 2005, 08:54 AM
Use PHP, it's not that hard. You can have a file like pwl.php which has an array, then have a page that checks the password in the $_SESSION and if it is not there, then direct them to a login page, if it is, check it against the array in the included pwl.php file and then if it is a correct combination, display the page. Not that tough.
Cello
January 6th, 2005, 09:35 AM
Yeldarb - could you elaborate if you've time? It's simple to you, but difficult for me! Would appreciate any additional information you care to give.
Deland02
January 6th, 2005, 04:38 PM
Yeh I agree, for a non PHP user it doesnt seam that straight forward. The major problem I have though is the host ive got to use doesnt support PHP, MySQL, or ASP.
The guy who asked me to produce the password login script has the following package:
Starter:-
100 MB of web space for £1.59† per month!
1500 MB data transfer (bandwidth) per month.
CGI/Perl Script enabled.
On-line file manager and full FTP access.
15 mail boxes (POP3).
Free WebMail.
Webalizer graphical web statistics (click to try).
Add FrontPage Extensions for £25 per year.
Unlimited e-mail forwarding addresses.
Quite limited in the stuff I can do really.
Any more suggestions?
aknatn
January 6th, 2005, 04:48 PM
First find out if this a Windows host and what webser it is running. If it is running Apache, then .htaccess is the way to go, if not then running a perl script is the way to go, here is a link to perl password resources:
http://cgi.resourceindex.com/Programs_and_Scripts/Perl/Password_Protection/
BTW: using php sessions isn't that hard, but it may be tough for a non-programmer.
Deland02
January 6th, 2005, 04:59 PM
Just emailed em now but ive got a funny feeling they wont be (sods law). I'll take a look at the link now. Ta
Powered by vBulletin® Version 4.1.10 Copyright © 2012 vBulletin Solutions, Inc. All rights reserved.