To create a username and password you will need to create or edit your .htaccess file.
You need at least four lines in .htaccess to set up password protection: AuthName "Realm name" AuthType Basic AuthUserFile /BASEDIR/.htpasswd require valid-user
/BASEDIR/ is the path to your root directory.
AuthName: Realm name a piece of text that appears on the dialogue box asking for the password. See what it does in practice and then you can decide what text you would like here.
AuthType: Only Basic is possible at present.
AuthUserFile: The existence of the AuthUserFile line suggests that you can call the .htpasswd file something else. That is true, but is best to call it .htpasswd, so that nobody can view its contents.
require: This says that any user validated by password is allowed.
As well as these entries in the .htaccess file, you will need to set up a .htpasswd file
The format of this file is simple. It consists of a series of usernames and passwords. Each line holds one username and the single password associated with it, separated by a colon. Here is an example:
You may think these passwords are rather unrealistic and difficult to remember – the reason for this is that they are encrypted for security. The .htpasswd file does not hold the actual passwords in clear text – it holds them in a coded form. If you are running Apache (at least on Unix) there is a command called htpasswd which will translate clear text passwords into this encrypted form. What many webmasters do is use an on-line tool to do this translation.
[...] There you will find 64018 more Infos: getportals.com/2008/06/16/how-to-create-a-sub-domain-in-apache-or-mysql-database-and-make-a-user-name-and-password-to-access-it/ [...] …
June 16th, 2008 at 10:17 am
A subdomain is configured by virtual host entries in httpd.conf.
Here is an example of what the file should look like:
Listen 80
NameVirtualHost *
<VirtualHost *>
ServerName http://www.domain.com
DocumentRoot /home/httpd/htdocs/
</VirtualHost>
<VirtualHost *>
ServerName subdomain.domain.com
DocumentRoot /home/httpd/htdocs/subdomain/
</VirtualHost>
To create a username and password you will need to create or edit your .htaccess file.
You need at least four lines in .htaccess to set up password protection:
AuthName "Realm name"
AuthType Basic
AuthUserFile /BASEDIR/.htpasswd
require valid-user
/BASEDIR/ is the path to your root directory.
AuthName: Realm name a piece of text that appears on the dialogue box asking for the password. See what it does in practice and then you can decide what text you would like here.
AuthType: Only Basic is possible at present.
AuthUserFile: The existence of the AuthUserFile line suggests that you can call the .htpasswd file something else. That is true, but is best to call it .htpasswd, so that nobody can view its contents.
require: This says that any user validated by password is allowed.
As well as these entries in the .htaccess file, you will need to set up a .htpasswd file
The format of this file is simple. It consists of a series of usernames and passwords. Each line holds one username and the single password associated with it, separated by a colon. Here is an example:
frances:WrU808BHQai36
john:iABCQFQs40E8M
lisa:FAdHN3W753sSU
You may think these passwords are rather unrealistic and difficult to remember – the reason for this is that they are encrypted for security. The .htpasswd file does not hold the actual passwords in clear text – it holds them in a coded form. If you are running Apache (at least on Unix) there is a command called htpasswd which will translate clear text passwords into this encrypted form. What many webmasters do is use an on-line tool to do this translation.
October 14th, 2011 at 8:50 am
Recent Blogroll Additions……
[...]usually posts some very interesting stuff like this. If you’re new to this site[...]……
October 17th, 2011 at 4:06 am
Related……
[...]just beneath, are numerous totally not related sites to ours, however, they are surely worth going over[...]……
October 19th, 2011 at 5:14 am
Gems form the internet…
[...]very few websites that happen to be detailed below, from our point of view are undoubtedly well worth checking out[...]……
October 19th, 2011 at 6:39 pm
Visitor recommendations…
[...]one of our visitors recently recommended the following website[...]…
October 22nd, 2011 at 7:37 am
Recommeneded websites…
[...]Here are some of the sites we recommend for our visitors[...]……
October 22nd, 2011 at 9:20 am
Sources…
[...]check below, are some totally unrelated websites to ours, however, they are most trustworthy sources that we use[...]……
October 22nd, 2011 at 11:24 pm
Gems form the internet…
[...]very few websites that happen to be detailed below, from our point of view are undoubtedly well worth checking out[...]……
October 26th, 2011 at 1:23 pm
Websites you should visit…
[...]below you’ll find the link to some sites that we think you should visit[...]……
October 26th, 2011 at 6:16 pm
Online Article……
[...]The information mentioned in the article are some of the best available [...]……
October 28th, 2011 at 6:07 am
Sites we Like……
[...] Every once in a while we choose blogs that we read. Listed below are the latest sites that we choose [...]……
October 28th, 2011 at 7:11 am
Check this out…
[...] that is the end of this article. Here you’ll find some sites that we think you’ll appreciate, just click the links over[...]……
October 28th, 2011 at 8:50 am
Blogs ou should be reading…
[...]Here is a Great Blog You Might Find Interesting that we Encourage You[...]……
October 28th, 2011 at 10:43 am
Another Title…
I saw this really good post today….
October 28th, 2011 at 1:49 pm
Superb website…
[...]always a big fan of linking to bloggers that I love but don’t get a lot of link love from[...]……
October 29th, 2011 at 3:13 pm
Tumblr article…
I saw someone talking about this on Tumblr and it linked to…
November 1st, 2011 at 11:57 am
Recommeneded websites…
[...]Here are some of the sites we recommend for our visitors[...]……
November 5th, 2011 at 5:03 am
Recent Blogroll Additions……
[...]usually posts some very interesting stuff like this. If you’re new to this site[...]……
November 5th, 2011 at 2:13 pm
Gems form the internet…
[...]very few websites that happen to be detailed below, from our point of view are undoubtedly well worth checking out[...]……
November 6th, 2011 at 11:00 pm
News info…
I was reading the news and I saw this really cool topic…
November 8th, 2011 at 5:09 am
Blogs ou should be reading…
[...]Here is a Great Blog You Might Find Interesting that we Encourage You[...]……
November 11th, 2011 at 4:58 pm
Tumblr article…
I saw someone writing about this on Tumblr and it linked to…
November 14th, 2011 at 1:06 pm
Websites worth visiting…
[...]here are some links to sites that we link to because we think they are worth visiting[...]……
November 16th, 2011 at 11:55 am
Gems form the internet…
[...]very few websites that happen to be detailed below, from our point of view are undoubtedly well worth checking out[...]……
November 21st, 2011 at 11:09 am
We got a nice list…
[...]juicy site with free links, on filesonic, mediafire, megaupload, fileserve, rapidshare[...]……
November 23rd, 2011 at 2:21 pm
Sites we Like……
[...] Every once in a while we choose blogs that we read. Listed below are the latest sites that we choose [...]……
November 24th, 2011 at 3:17 am
Websites you should visit…
[...]below you’ll find the link to some sites that we think you should visit[...]……
November 25th, 2011 at 3:33 am
Related……
[...]just beneath, are numerous totally not related sites to ours, however, they are surely worth going over[...]……
December 5th, 2011 at 1:57 am
agria bra kattförsäkring…
[...]n Finally a person who’s writing about something other than superficioul subj 12[...]…
December 5th, 2011 at 6:26 pm
karta paris…
[...]j I own a similar website to this one and I was just curious if you get a lot ge[...]…
January 1st, 2012 at 12:30 pm
Websites worth visiting…
[...]here are some links to sites that we link to because we think they are worth visiting[...]……
January 3rd, 2012 at 7:20 pm
Websites you should visit…
[...]below you’ll find the link to some sites that we think you should visit[...]……
January 4th, 2012 at 6:27 am
……
Great post, I conceive website owners should acquire a lot from this web blog its rattling user pleasant….
January 5th, 2012 at 3:08 pm
Looking around…
While I was browsing yesterday I noticed a excellent post concerning…
January 7th, 2012 at 7:58 am
Check this out…
[...] that is the end of this article. Here you’ll find some sites that we think you’ll appreciate, just click the links over[...]……
January 8th, 2012 at 6:14 am
News info…
I was reading the news and I saw this really interesting topic…
January 9th, 2012 at 7:22 am
Yahoo results…
While searching Yahoo I discovered this page in the results and I didn’t think it fit…
January 10th, 2012 at 6:10 am
Links…
[...]Sites of interest we have a link to[...]……
January 11th, 2012 at 12:24 pm
Tumblr article…
I saw someone writing about this on Tumblr and it linked to…
January 19th, 2012 at 7:43 pm
… [Trackback] …
[...] There you will find 64018 more Infos: getportals.com/2008/06/16/how-to-create-a-sub-domain-in-apache-or-mysql-database-and-make-a-user-name-and-password-to-access-it/ [...] …
January 27th, 2012 at 7:35 pm
… [Trackback] …
[...] Read More: getportals.com/2008/06/16/how-to-create-a-sub-domain-in-apache-or-mysql-database-and-make-a-user-name-and-password-to-access-it/ [...] …
January 27th, 2012 at 11:28 pm
Websites worth visiting…
[...]here are some links to sites that we link to because we think they are worth visiting[...]……
February 5th, 2012 at 11:05 pm
Sources…
[...]check below, are some totally unrelated websites to ours, however, they are most trustworthy sources that we use[...]……