Hello, I would like to find a way of successfully redirecting a call to one of our files made through a virtual include. The following redirect works quite happily when the file request is made directly through the browser address bar but if I call it via a virtual include it fails to redirect. This is an example of one of 500 redirects that will have to be made, all being piped through the same template_portal.sssi just with different params being passed. Any help on where I'm going wrong here would be most appreciated? The file request example: <!--#include virtual="/path/to/dir/file.shtml" --> Code (markup): Present RewriteRule example: RewriteRule ^file.shtml$ http://site.co.uk/path/to/new/dir/portal_template.sssi?location=#®ion=#&product=#&type=#&nav=#&stick=#&id=#&q=# [R,L] Code (markup): Many thanks, mat
I may be wrong; but I don't think what you want to do will work. http://httpd.apache.org/docs/howto/ssi.html http://www.apacheweek.com/features/ssi http://bignosebird.com/ssi.shtml
Hi flawebworks, Cheers for the points and sounds about right autually. A friend reminded me that to fire the RewriteRule the call would need to be made as a HTTP request. As the include is handled differently by Apache this type of request never happens... I'm going look at zero'in the contents of the called file and daisy chaining the new code or include into it. Cheers again and thanks for the speedy reply. mat