Basic Password Protection

Hello. I recently purchased the Password protection tutorial, as I need to be able to password protect one of the webpages on my site. The tutorial was quite good, and Ben did a great job explaining everything, but it simply won’t work.

I am trying to use the basic .htaccess and passwd option, as that is the basic kind of security I need. I followed all of the steps included accurately (went through twice to be sure), and there is no change on the site. No matter where I place the file (index or the intended page) I am never asked for login credentials at all. Please help!

Without seeing what you have done with the htaccess and passwd files it’s hard to say what is going on.

Perhaps you can copy and paste (please mark it as Preformatted text </>) what you have.

The htaccess (this has been placed in the sub-folder for the page I want the password protection on):
</AuthType Basic
AuthName “My Protected Area”
AuthUserFile G:\PleskVhosts\oldzionlutheran.org\index/.htpasswd
Require valid-user/>

The passwd (in the index directory):
</member:$apr1$2s69471r$GzIMb3EcR0IPzVNrP9oz41/>

If you go to www DOT oldzionlutheran DOT org, click on This Sunday tab > Liturgy and Music. The Liturgy and Music page is what I am trying to protect with the simple pass word. Thank you.

First off,
My answer above about " (please mark it as Preformatted text </>)" might have confused you.

To mark things like that you select the text and select the </> right above where you type your post:

.

Sorry about not being clearer.

I don’t have the video you are using as a guide, but there are a few things.

Not sure where you got the path:
AuthUserFile G:\PleskVhosts\oldzionlutheran.org\index/.htpasswd
That doesn’t look right.

  1. You usually don’t have a drive letter in this path
  2. Plesk is a control panel
  3. most paths on web servers use forward slashes / not backslashes \.

Also, keep in mind that this method of securing part or all of a website only works if the webserver is Apache. It will not work with any other web server (Windows, Nginx, IIS, etc).

You didn’t say who the hosting company is, but the \ is a windows thing.

Here is a good article on setting up a password:

Sorry for not formatting that correctly.

Yes, that did not seem right when I saw that either, but I followed the tasks in the video by Ben (a php code file that indicated the file path).

The website is technically hosted on Go-Daddy, so I guess that could be the problem? The website itself is built on RapidWeaver on my mac.

Thanks again.

That might be the issue. Godaddy has a bunch of different hosting plans, many are not Linux/Apache but Windows.

Already took the step of contacting them - thanks for the heads up. This is quite an annoying task.

OK, so it turns out I do indeed have a windows server with a Plesk Admin panel - which seems to mean that all the advice in this tutorial I purchased through RapidWeaver is completely useless.

Is there a way to make this work on a Windows server in a similar way? This kind of higher level network stuff is a little out of my intermediate hands…

I know you probably don’t want to hear this, but you are going to continue to have issues with Windows server.

This is how godaddy gets you, they offer Linux/Apache hosting at a higher price. It’s the old bait and switch thing, it sounds cheap but by the time you get a service that actually works for you it costs more than competitors.

I’d suggest you either “upgrade” to a Linux/Apache plan, or change to a different hosting company.

I would probably cut my losses and change host now, you probably will eventually anyway.

They actually offered me a switch to a Linux hosting plan with cPanel at a lower price…

Although - I have been looking through their plesk administration panel, and have found options to password protect a directory through them, but alas, that does not seem to work either; shocked though I may be.

Actually - I did get it to work through the Plesk administration panel. That was slightly infuriating, but just the basic that I needed. Thanks for your help!

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.