Archives pour la catégorie apache

rewrite rules

redirect HOST != ‘blog.hio.fr’ to blog.hio.fr

RewriteEngine on
RewriteCond %{HTTP_HOST} !^blog\.hio\.fr$ [NC]
RewriteRule ^(.*)$ http://blog.hio.fr/$1? [L,R=301]

APACHE zend framework vhost

<VirtualHost *:80>
        ServerAdmin webmaster@localhost
        ServerName sub.domain.tld
        SetEnv APPLICATION_ENV "development"
        DocumentRoot /var/www/sub.domain.tld/public
        <Directory />
                Options FollowSymLinks
                AllowOverride None
        </Directory>
        <Directory /var/www/sub.domain.tld/public>
                Options Indexes FollowSymLinks MultiViews
                AllowOverride All
                Allow from all
        </Directory>
 
        ErrorLog /var/log/apache2/sub.domain.tld.error.log
        CustomLog /var/log/apache2/sub.domain.tld.access.log combined
</VirtualHost>