Hi,

I was wondering if it is possible to add some basic RewriteRules to the ZF 
.htaccess?
Is it possible to match certain urls while there is not a corresponding 
Controller/Action/View or Routes configured for these paths?

Something like:

SetEnv APPLICATION_ENV development

RewriteEngine On
RewriteRule ^foo http://%{HTTP_HOST}/bar [R=301,NC]

RewriteCond %{REQUEST_FILENAME} -s [OR]
RewriteCond %{REQUEST_FILENAME} -l [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^.*$ - [NC,L]
RewriteRule ^.*$ index.php [NC,L]

where 'foo' is not existing in the ZF application and 'bar' is.
So '.../foo' which is not really existing in my application should be 
redirected to '../bar' which has an existing BarController with actions and 
views.

Thanks,

Laurens

Reply via email to