Hi,
I'm trying to attach a jpg image to an email (using the following code) but after it's downloaded if I try to open the image it's saying the image contains no data. If I try to open it in photoshop it says the marker segment length is too short.
I can successfully open the original jpg file directly in my browser (off my server - the one it's sending) so it must be something I've done here with the type or encoding to stuff it up between being sent and me opening it?
$mail->attach (
type => 'image/jpeg',
encoding => '-guess',
body_path => '/path/to/file',
filename => "12587.jpg"
);
Anyone know?
Cheers,
Regan.
I'm trying to attach a jpg image to an email (using the following code) but after it's downloaded if I try to open the image it's saying the image contains no data. If I try to open it in photoshop it says the marker segment length is too short.
I can successfully open the original jpg file directly in my browser (off my server - the one it's sending) so it must be something I've done here with the type or encoding to stuff it up between being sent and me opening it?
$mail->attach (
type => 'image/jpeg',
encoding => '-guess',
body_path => '/path/to/file',
filename => "12587.jpg"
);
Anyone know?
Cheers,
Regan.