Good evening.
I've got apache2 on squeeze.
In /var/www/www.etxea.org/htdocs/.htaccess I've got the following content ...

IndexIgnore *
<IfModule mod_rewrite.c>
  RewriteEngine on
# Any HTTP request other than those for index.php, images, and robots.txt is treated as a request for your index.php file
  RewriteCond $1 !^(index\.php|images|robots\.txt|user_guide)
  RewriteRule ^(.*)$ /index.php/$1 [L]
</IfModule>

... and It really works.
But I want not to use .htaccess, I mean, to copy this content to /etc/apache2/sites-available/www.etxea.org, just to (after enabling with a2ensite www.etxea.org and /etc/init.d/apache2 restart) make it work just the same.
The www.etxea.org file content is the following ...

<VirtualHost *>
    ServerAdmin webmas...@etxea.org
    ServerName  www.etxea.org
    ServerAlias etxea.org

    # Indexes + Directory Root.
    DirectoryIndex index.php index.html
    DocumentRoot /var/www/www.etxea.org/htdocs/
    <Directory “/var/www/www.etxea.org/htdocs/”>
        AllowOverride All
        IndexIgnore *
        <IfModule mod_rewrite.c>
        RewriteEngine on
# Any HTTP request other than those for index.php, images, and robots.txt is treated as a request for your index.php file
        RewriteCond $1 !^(index\.php|images|robots\.txt|user_guide)
        RewriteRule ^(.*)$ /index.php/$1 [L]
        </IfModule>
    </Directory>

    # CGI Directory
    ScriptAlias /cgi-bin/ /var/www/www.etxea.org/cgi-bin/
    <Location /cgi-bin>
        Options +ExecCGI
    </Location>

    # Logfiles
    ErrorLog  /var/www/www.etxea.org/logs/error.log
    CustomLog /var/www/www.etxea.org/logs/access.log combined
</VirtualHost>

But I regret It doesn't work. What's the problem? Is the IfModule located where it must be or I've missunderstood the place?
Thank you.


--
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/50904061.3090...@gmail.com

Reply via email to