Weird one--PHP parsing jpg image!?
| From: | dphillips at rfdinc dot com | Date: | Thu, 08 Feb 2001 14:04:59 +0000 |
| Subject: | Weird one--PHP parsing jpg image!? | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-38751@lists.php.net to get a copy of this message | ||
Our site, under construction, displays a gallery of jpeg images. We're
using Apache with PHP 4.0.2 compiled in, on Windows 98SE. At one point we
recall our page with $PHP_SELF, and it generates a URL like
http://localhost/php/php.exe/sandbox/gallery_demo.php.
The weird thing is that some of the images show up as broken links. Okay,
so we get the link properties and copy & paste the URL into the browser,
like: http://localhost/php/php.exe/sandbox/images/rainbow.jpg.
We get back
an error message that PHP found an illegal character in line 7 of the jpeg
file!?
If we excise the php/php.exe part that's generated by $PHP_SELF, making
the URL simply http://localhost/sandbox/gallery_demo.php then
all the
images display correctly. So I guess we have two questions:
1. How to make PHP not treat the jpg files as code?
2. Or, as a work around, how to ensure the jpg image passes through PHP,
as most of our images do successfully?
Thanks.
--David
---------------------------------------
David M. Phillips
eBoing, Inc. dphillips@eboing.com
Austin, Texas