Need some help with Apache .htaccess
- by Legend
I am trying to setup an application that was built using the Zend framework. Let's say my subdomain is:
http://subdomain.domain.com
and that it points to the following:
http://www.domain.com/projectdir/
The structure of the project dir is the following:
application/
...
...
library/
...
...
public/
...
...
.htaccess
The contents of the htaccess are:
SetEnv APPLICATION_ENV production
RewriteEngine On
# skip existing files and folders
RewriteCond %{REQUEST_FILENAME} -s [OR]
RewriteCond %{REQUEST_FILENAME} -l [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^.*$ - [NC,L]
# send everything to index
RewriteRule ^.*$ index.php [NC,L]
While this works, the child objects on the page are being directed to the domain i.e., the image URLs (and the CSS files etc.) are broken because they are being redirected to something like:
http://www.domain.com/images/image.png
Can someone please tell me how to fix this?