I'm helping a friend make a simple website and we want to have one page or a part where members only can log in with a password.
I'm not sure how to do that so if someone could provide the code I would greatly appreciate it.
Web page help
Re: Web page help
Depending on how you want to achieve this, "simple" and security may not exactly go hand in hand. If you want to do this via PHP, etc, then it's certainly not simple.
If your hosting service uses Apache, the simplest way is just to edit your .htaccess file and set up your web hosting with member access and passwords.
Read here:
http://www.elated.com/articles/password ... -htaccess/
If your hosting service uses Apache, the simplest way is just to edit your .htaccess file and set up your web hosting with member access and passwords.
Read here:
http://www.elated.com/articles/password ... -htaccess/
Re: Web page help
That does seem a bit complicated. I'm not sure if I explained right. On the home page we want a link that is for members only. I guess this is a page, but just a spot where you need a username and password to enter.
Re: Web page help
This website uses PHP. If you want something like that, you'll have a lot of work to do, so that's not something I recommend.
.htaccess is the easiest method I can think of. You'll click on a link that leads to a directory and an HTML file. The .htaccess file will tell Apache that you need a username and password to see the contents of that directory or file. There really isn't anything simpler.
.htaccess is the easiest method I can think of. You'll click on a link that leads to a directory and an HTML file. The .htaccess file will tell Apache that you need a username and password to see the contents of that directory or file. There really isn't anything simpler.
Re: Web page help
OK, only I am using Internet Explorer 7. Does this matter?
Re: Web page help
I misread the first reply where it says "if the hosting service uses Apache".
So I need to check with the company hosting the site and see if they use Apache, right?
So I need to check with the company hosting the site and see if they use Apache, right?
Re: Web page help
It's pretty much a matter of whether you have Linux or Windows hosting. Linux will be apache, Windows (probably) won't be.
If you're not sure, then yes you'll have to check. Or post the name of the provider here and someone will check. Or ftp in and look for .htacess files. Or... give up (which is where you're going to end up anyway, once you realize the amount of trouble involved)
If you're not sure, then yes you'll have to check. Or post the name of the provider here and someone will check. Or ftp in and look for .htacess files. Or... give up (which is where you're going to end up anyway, once you realize the amount of trouble involved)