.htaccess: verschil tussen versies
Uit dotSearch
(Nieuwe pagina aangemaakt met '== Beveilig map met user/pass == AuthUserFile /home/sequence1980/localfolder/.htpasswd AuthType Basic AuthName "My Secret Folder" Require valid-user') |
|||
| (3 tussenliggende versies door een andere gebruiker niet weergegeven) | |||
| Regel 1: | Regel 1: | ||
| + | * [http://net.tutsplus.com/tutorials/other/the-ultimate-guide-to-htaccess-files/ The ultimate guide to .htaccess] | ||
| + | * [http://www.noupe.com/php/htaccess-techniques.html The Definitive Guide to .htaccess techniques] | ||
| + | |||
== Beveilig map met user/pass == | == Beveilig map met user/pass == | ||
AuthUserFile /home/sequence1980/localfolder/.htpasswd | AuthUserFile /home/sequence1980/localfolder/.htpasswd | ||
| + | |||
AuthType Basic | AuthType Basic | ||
| + | |||
AuthName "My Secret Folder" | AuthName "My Secret Folder" | ||
| + | |||
Require valid-user | Require valid-user | ||
| + | |||
| + | |||
| + | == Domain based redirection == | ||
| + | |||
| + | Options +FollowSymlinks | ||
| + | |||
| + | RewriteEngine On | ||
| + | |||
| + | |||
| + | RewriteCond %{HTTP_HOST} ^(www\.)?kokinternetmarketing.nl [NC,OR] | ||
| + | |||
| + | RewriteCond %{HTTP_HOST} ^(www\.)?kok-internet-marketing.nl [NC] | ||
| + | |||
| + | RewriteRule ^(.*)$ http://dotsearch.nl/$1 [R=301,NC] | ||
| + | |||
| + | |||
| + | RewriteCond %{HTTP_HOST} ^(www\.)?x-ite.nl [NC,OR] | ||
| + | |||
| + | RewriteCond %{HTTP_HOST} ^(www\.)?rudecock.com [NC] | ||
| + | |||
| + | RewriteRule ^(.*)$ http://www.ruudkok.nl/$1 [R=301,NC] | ||
Huidige versie van 12 aug 2011 om 20:17
Beveilig map met user/pass[bewerken]
AuthUserFile /home/sequence1980/localfolder/.htpasswd
AuthType Basic
AuthName "My Secret Folder"
Require valid-user
Domain based redirection[bewerken]
Options +FollowSymlinks
RewriteEngine On
RewriteCond %{HTTP_HOST} ^(www\.)?kokinternetmarketing.nl [NC,OR]
RewriteCond %{HTTP_HOST} ^(www\.)?kok-internet-marketing.nl [NC]
RewriteRule ^(.*)$ http://dotsearch.nl/$1 [R=301,NC]
RewriteCond %{HTTP_HOST} ^(www\.)?x-ite.nl [NC,OR]
RewriteCond %{HTTP_HOST} ^(www\.)?rudecock.com [NC]
RewriteRule ^(.*)$ http://www.ruudkok.nl/$1 [R=301,NC]