You can edit "password" in .htaccess to be the password you want, then when you see the login box just enter the same password. If you have installed Price Tapestry into a sub-directory you will need to modify RewriteBase in .htaccess to include the subdirectory; for example:
Hello Asep,
If you are using Apache, here as an easy way to make your /admin/ folder password protected. Create a new file called admin/login.php as follows:
<?php
require("../includes/common.php");
require("../includes/admin.php");
if ($_POST["password"])
{
setcookie($_POST["password"],"1");
header("Location: ".$config_baseHREF."admin/");
exit();
}
require("admin_header.php");
print "<h2>Admin Login</h2>";
print "<form name='f' method='post' action='login.php'>";
print "Enter Password:<br />";
print "<input type='text' id='password' name='password' /><br /><br />";
print "<input type='submit' value='Login' />";
print "</form>";
print "<script type='text/javascript'>document.f.password.focus();</script>";
require("admin_footer.php");
?>
Now, create a new file called admin/.htaccess as follows:
Options -MultiViews
RewriteEngine On
RewriteBase /admin/
RewriteCond %{REQUEST_URI} !login.php$
RewriteCond %{HTTP_COOKIE} !(password)
RewriteRule .* login.php [R]
You can edit "password" in .htaccess to be the password you want, then when you see the login box just enter the same password. If you have installed Price Tapestry into a sub-directory you will need to modify RewriteBase in .htaccess to include the subdirectory; for example:
RewriteBase /shopping/admin/
Hope this helps!
Cheers,
David.