How to password protect part of my website?

by Dayne Dylan Banned
5 replies
Warriors,

I want to have a section on my website that I can password protect for only certain members. This is a basic HTML website, not a blog. What is the easiest way to do this?

Thanks!
#part #password #protect #website
  • Profile picture of the author Tim Dixon
    Hi Dayne.

    The easiest way is probably to just use a .htaccess and .htpasswd file combination to protect a certain directory.

    Lots of info on the web about it but here's a fairly straightforward explanation:
    How to Password Protect a Directory on Your Website (thesitewizard.com)

    Tim
    {{ DiscussionBoard.errors[447773].message }}
  • Profile picture of the author Dayne Dylan
    Banned
    Perfect Tim! This is my first time to actually do this.
    {{ DiscussionBoard.errors[447775].message }}
  • Profile picture of the author Marie Pugh
    Hi Dayne

    If your host uses cpanel:

    First thing you need to do is make sure there is a seperate folder created for you to put the password protected pages and files into - you can call it "members" or whatever you want. You can just do that in "File Manager" in cpanel if you want.

    Then, look for the icon for "Password Protect Directories". Then, click through until you find the folder you want to protect, then click directly on that folder. That will open up a section for you to set it up.

    The first thing is to choose a name for the protected directory - this will be what shows up in the pop up box that comes up in people's browsers when they try to access the protected area. It can be anything you want.

    Then choose a username and password. But - these will be the same for everyone. These are then what will be used whenever someone sees the popup box.

    Obviously, if you are wanting something where everyone has their own passwords etc. you will need a membership script of some kind. But - this works good for simple things. And, you can always change it every now and then. It is a good way to get people to sign up for a mailing list. Tell them you will be changing the password from time to time, so they need to be signed up so they can get the new ones as they come out

    HTH

    Marie
    {{ DiscussionBoard.errors[447786].message }}
  • Profile picture of the author Dayne Dylan
    Banned
    Would it be easier to just add a blog section via Wordpress and password protect that?
    {{ DiscussionBoard.errors[447795].message }}
  • Profile picture of the author jonhel
    If providing a single password for all these members is an acceptable solution then what Tim suggested is a simple approach to achieve this. It will only take you several minutes to put in place.

    Jonathan
    {{ DiscussionBoard.errors[447933].message }}

Trending Topics