Jump to content

Images have a carriage return at the start of the file


Recommended Posts

Hi All,

 

Hope somebody can help me here. Don't know which board to post so I'll just put it here.

 

I have been stumped on how this is happening.  Every time I download an image there is a 0A prepended at the start of the file. Now images such as a JPEG, which usually starts with FF D8 FF E1 or FF D8 FF E0 is not readable by image viwers/apps because it gets confused on the image type.

 

Here is an example in hex and human-redable text below it.

0A FF D8 FF E1 00 24 45 78 69 66 00 00 49 49 2A 00 08 00 00 00 01 00 98 82 02 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 FF EC 00 11 44 75 63 6B 79 00 01 00 04 00 00 00 44 00 00 FF E1 03 1D 68 74 74 70 3A 2F 2F 6E 73 2E 61 64 6F 62 65 2E 63 6F 6D 2F 78 61 70 2F 31 2E 30 2F 00 3C 3F 78 70 61 63 6B 65 74 20 62 65 67 69 6E 3D 22 EF BB BF 22 20 69 64 3D 22 57 35 4D 30 4D 70 43 65 68 69 48 7A 72 65 53 7A 4E 54 63 7A 6B 63 39 64 22 3F 3E 20 3C 78 3A 78 6D 70 6D 65 74 61 20 78 6D 6C 6E 73 3A 78 3D 22 61 64 6F 62 65 3A 6E 73 3A 6D 65 74 61 2F 22 20 78 3A 78 6D 70 74 6B 3D 22 41 64 6F 62 65 20 58 4D 50 20 43 6F 72 65 20 35 2E 36 2D 63 30 31 34 20 37 39 2E 31 35 36 37 39 37 2C 20 32 30 31 34 2F 30 38 2F 32 30 2D 30 39 3A 35 33 3A 30 32 20 20 20 20 20 20 20 20 22 3E 20
Note that I have a testing site and this does not happen there. The downloaded files are fine. 
Ducky   K ÿá vhttp://ns.adobe.com/xap/1.0/ <?xpacket begin="" id="W5M0MpCehiHzreSzNTczkc9d"?> <x:xmpmeta xmlns:x="adobe:ns:meta/" x:xmptk="Adobe XMP Core 5.0-c060 61.134777, 2010/02/12-17:32:00 "> <rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">

Has anyone encountered this before? What did you do to fix it?

 

 

 

Thanks and Regards,

Marky

some code you have, that's either part of the original uploading or downloading of the file, probably contains a new-line character in it, outside of any <?php ?> tags, and this character is getting prepended to the file data.

Edited by mac_gyver
This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.