I am having a problem with Apache. What it does is this: Take /index.php file containing an code with src set to relative path myimg.jpg, both in the root of my server. So, www.mysite.com would show the image as would www.mysite.com/index.php.
However, if I access www.mysite.com/index.php/ (with a trailing slash) it does the odd thing of executing index.php code as it would be inside an index.php folder (e.g. /index.php/index.php), thus not showing the image anymore.
This is a simple example that's easy to solve with absolte addressing etc, the problem I am getting from this a security one that's not so easily fixed.
So, how can I get Apache to give a 403 or 404 when files are accessed "as folders"?