Warning: include(../style.php) [function.include]: failed to open stream: No such file or directory in /home/galacnet/domains/galacnet.com/public_html/faq/faq-htaccess-passwordprotect.php on line 14

Warning: include() [function.include]: Failed opening '../style.php' for inclusion (include_path='.:/usr/local/lib/php') in /home/galacnet/domains/galacnet.com/public_html/faq/faq-htaccess-passwordprotect.php on line 14

Warning: include(../body.php) [function.include]: failed to open stream: No such file or directory in /home/galacnet/domains/galacnet.com/public_html/faq/faq-htaccess-passwordprotect.php on line 15

Warning: include() [function.include]: Failed opening '../body.php' for inclusion (include_path='.:/usr/local/lib/php') in /home/galacnet/domains/galacnet.com/public_html/faq/faq-htaccess-passwordprotect.php on line 15

Warning: include(../logo.php) [function.include]: failed to open stream: No such file or directory in /home/galacnet/domains/galacnet.com/public_html/faq/faq-htaccess-passwordprotect.php on line 16

Warning: include() [function.include]: Failed opening '../logo.php' for inclusion (include_path='.:/usr/local/lib/php') in /home/galacnet/domains/galacnet.com/public_html/faq/faq-htaccess-passwordprotect.php on line 16

Warning: include(../top-tool.php) [function.include]: failed to open stream: No such file or directory in /home/galacnet/domains/galacnet.com/public_html/faq/faq-htaccess-passwordprotect.php on line 17

Warning: include() [function.include]: Failed opening '../top-tool.php' for inclusion (include_path='.:/usr/local/lib/php') in /home/galacnet/domains/galacnet.com/public_html/faq/faq-htaccess-passwordprotect.php on line 17

Warning: include(../left-paid.php) [function.include]: failed to open stream: No such file or directory in /home/galacnet/domains/galacnet.com/public_html/faq/faq-htaccess-passwordprotect.php on line 18

Warning: include() [function.include]: Failed opening '../left-paid.php' for inclusion (include_path='.:/usr/local/lib/php') in /home/galacnet/domains/galacnet.com/public_html/faq/faq-htaccess-passwordprotect.php on line 18

Warning: include(../left-free.php) [function.include]: failed to open stream: No such file or directory in /home/galacnet/domains/galacnet.com/public_html/faq/faq-htaccess-passwordprotect.php on line 19

Warning: include() [function.include]: Failed opening '../left-free.php' for inclusion (include_path='.:/usr/local/lib/php') in /home/galacnet/domains/galacnet.com/public_html/faq/faq-htaccess-passwordprotect.php on line 19

Warning: include(../faq-top.php) [function.include]: failed to open stream: No such file or directory in /home/galacnet/domains/galacnet.com/public_html/faq/faq-htaccess-passwordprotect.php on line 20

Warning: include() [function.include]: Failed opening '../faq-top.php' for inclusion (include_path='.:/usr/local/lib/php') in /home/galacnet/domains/galacnet.com/public_html/faq/faq-htaccess-passwordprotect.php on line 20

Configuring .htaccess FaQ - Creating a Password protected Folder

This will generate a pop-up login request to the person access the folder for contents. 2 files are to be created and placed in the folder of interest.

Create a file or insert into your ".htaccess" file
order allow,deny
allow from all
require valid-user
Authname DirectoryName
AuthPAM_Enabled off
Authtype Basic
AuthUserFile /location of htpasswd/.htpasswd

Then create another file called ".htpasswd". Log into SSH for this and excute this command.
/usr/bin/htpasswd -c /location of the htaccess file/.htpasswd

This will create a new .htpasswd file in that specified location.
You will then be prompted for the username and password.

To add a new user to the same file, leave out the -c in the commandline.


Back to FaQ Section  

Warning: include(../right-top.php) [function.include]: failed to open stream: No such file or directory in /home/galacnet/domains/galacnet.com/public_html/faq/faq-htaccess-passwordprotect.php on line 76

Warning: include() [function.include]: Failed opening '../right-top.php' for inclusion (include_path='.:/usr/local/lib/php') in /home/galacnet/domains/galacnet.com/public_html/faq/faq-htaccess-passwordprotect.php on line 76

Warning: include(../right-mid.php) [function.include]: failed to open stream: No such file or directory in /home/galacnet/domains/galacnet.com/public_html/faq/faq-htaccess-passwordprotect.php on line 77

Warning: include() [function.include]: Failed opening '../right-mid.php' for inclusion (include_path='.:/usr/local/lib/php') in /home/galacnet/domains/galacnet.com/public_html/faq/faq-htaccess-passwordprotect.php on line 77

Warning: include(../right-bottom.php) [function.include]: failed to open stream: No such file or directory in /home/galacnet/domains/galacnet.com/public_html/faq/faq-htaccess-passwordprotect.php on line 78

Warning: include() [function.include]: Failed opening '../right-bottom.php' for inclusion (include_path='.:/usr/local/lib/php') in /home/galacnet/domains/galacnet.com/public_html/faq/faq-htaccess-passwordprotect.php on line 78

Warning: include(../bottom-ad.php) [function.include]: failed to open stream: No such file or directory in /home/galacnet/domains/galacnet.com/public_html/faq/faq-htaccess-passwordprotect.php on line 79

Warning: include() [function.include]: Failed opening '../bottom-ad.php' for inclusion (include_path='.:/usr/local/lib/php') in /home/galacnet/domains/galacnet.com/public_html/faq/faq-htaccess-passwordprotect.php on line 79

Warning: include(../bottom.php) [function.include]: failed to open stream: No such file or directory in /home/galacnet/domains/galacnet.com/public_html/faq/faq-htaccess-passwordprotect.php on line 80

Warning: include() [function.include]: Failed opening '../bottom.php' for inclusion (include_path='.:/usr/local/lib/php') in /home/galacnet/domains/galacnet.com/public_html/faq/faq-htaccess-passwordprotect.php on line 80