I am working on a website where I have configured apache to point the 404 page to index.php via:
"ErrorDocument 404 /index.php"
so i can parse the url arguments manually. I am currently writing an image wrapper so if you go to for example
"myssite.com/image/test"
it will display a test image with the the php header set to image/jpeg in-order to mask the images physical location on the server as images will later be managed by a database. when I display this image via php like so:
"echo '<img src="/image/test" alt="some_text">';"
It is displayed correctly. if this same thing is done with javascript and inserted onto the page, It receives a 404 error and does not load the image.
I figure I either need to make apache not report a 404 at all, or somehow change the way javascript handles it. Any suggestions?
The 404 error was fixed by adding the following to httpd.conf:
Although that did not help with the image not being displayed, which caused me to to look closer at the function displaying the image. Something is going bad when I use a cropping script prior to the image displaying causing more than likely an issue with the header. this should require minor back-end changes on my part.
thanks for the help everyone.