Forum Moderators: phranque
AuthType Basic
AuthName "System Administration"
AuthUserFile /Stupidly/Long/Path/.htpasswd
require valid-user
php_flag magic_quotes_gpc On
Currently, I have to log into each subdomain, using the same username and password for each subdomain. How can I change the htaccess file so that when I log into any subdomain, I am logged into all the domains?
I am doing this on a linux webhost so I can not use the http.conf.
Thanks for all your help,
Webmaster who is trying to take over the world.
Along with the 401 response, certain other information will be passed back to the client. In particular, it sends a name which is associated with the protected area of the web site. This is called the realm, or just the authentication name. The client browser caches the username and password that you supplied, and stores it along with the authentication realm, so that if other resources are requested from the same realm, the same username and password can be returned to authenticate that request without requiring the user to type them in again. This caching is usually just for the current browser session, but some browsers allow you to store them permanently, so that you never have to type in your password again.The authentication name, or realm, will appear in the pop-up box, in order to identify what the username and password are being requested for.
Because it is a function of the browser to store the authname (or realm), there is no server-side fix... "The crown of the King of the realm of Rohan.example.com fits not the King of the realm of Gondor.example.com!
The only work-around I can think of is to use the "Remember Passwords" function of your browser, and set a master browser password above those (See Firefox password controls, for example).
Jim