How to fix a pjpeg image file error
By Brandon Wilcox
Copyright © 2008 Evolve Marketing Ltd. All rights reserved.
Why can't you upload, download or save a pjpeg file? And how does your jpeg or jpg become encoded as a pjpeg image? What exactly is the difference between a pjpeg and a jpeg or a jpg?
Here's the scenario... I'm uploading an image into the photo gallery on a client's website and I get this pjpeg image upload error message...
Error: The filetype image/pjpeg is not allowed and has been deleted.
Everyone knows what a jpeg and a jpg is, but WTF is a pjpeg?
I ran into this problem a few times trying to upload clients' images to the photo gallery on their website. I searched the web, spoke to uber techies, tore my hair out - nothing worked and I was never able to solve this problem until now.
So I will share the solution with you.
Firstly, we use the Corlette Lab Gallery plugin on our client's websites running the e107 content management system, but I have no doubt this problem affects other photo galleries and other CMS too. I found reference on the web to Joomla users experiencing image upload problems. For example, this user trying to upload "little-baby-monkeys.jpg" got this pjpeg error message...
[name] => little-baby-monkeys.jpg [type] =>
image/pjpeg [tmp_name] =>
C:\PHP\uploadtemp\php1839.tmp [error] => 0 [size][html] => 105075
I also found reference to Chrome users not being able to copy and save images due to the pjpeg error.
I ran up three major blind alleys (and lots of smaller ones) while trying to figure this problem out.
Blind Alley #1
A lot of people said the problem was related to file size, or IE spazzing out and increasing the file size horrendously and causing an error. After wasting time on this avenue, I now know it is not the problem.
Blind Alley #2
A number of supposed experts simply recommended adding the filetype pjpeg to the list of allowed filetypes. I tried this and it does not work.
Blind Alley #3
In trying to find out what pjpeg stands for, i.e. what it is an acronym of, everyone said: "Progressive jpeg". I wasted a lot of time on this one. The progressive jpeg thing may or may not be true, but either way I believe it's a red herring. As a result of my findings I have come to the conclusion, rightly or wrongly, that what it really stands for is: "Protected jpeg".
pjpeg stands for "protected jpeg"
Yes folks, I believe pjpeg is really an acronym of "protected jpeg".
Tutorial for fixing pjpeg error
In this tutorial I will run you through the problem and how I fixed it. In the following screenshot you'll see I tried to upload two jpg images into a Corlette Lab Gallery photo album. One uploaded fine while the other generated this error message:
Error(s) detected:
The file did not upload. Filename: '182_080426-low-res.jpg'
Error: The filetype image/pjpeg is not allowed and has been deleted. (7)


I processed both images through Photoshop to get them to the right size and resolution, and yet one went in okay and the other didn't.
I spoke to the photographer who supplied the photos and he said there was some unreadable information on the problem image and it must be something I was doing wrong in Photoshop. Very unhelpful, especially as both images were processed in exactly the same way.
But it gave me the clue I needed.
I went into Photoshop's File\File Info menu and saw these entries in the Author box and the Copyright Notice box of the problem photo, but were blank on the photo that uploaded okay...


Problem identified!
You can't upload the image because the photographer added copyright protection! That's why I believe pjpeg stands for protected jpeg.
In this photographer's case it was some default setting because he had no idea it had even been added, let alone what the ramifications might be. He must have done some processing on the problem photos that he didn't do with the others, and the copyright information was automatically appended.
Fixing the pjpeg image error
In Photoshop's File\File Info menu, click on the Advanced tab and then expand the XMP Rights Management Properties entry as follows. You'll see the photographer's name after the copyright symbol on the bottom line...

Now hit the Delete button and begone. Next, expand the ns.adobe.com line above it as follows...

You'll notice the photographer's name listed as the author. Hit the Delete button on this one too. You'll end up with a list like this...

Now click the OK button and save the image over the top of the existing one ready to upload again...

If you go back into the File\File Info menu you'll see the Description tab is now totally clean...

Next, upload the photo to your gallery again and hey presto, no problemo!

Blatant plug: Looking for an effective website solution? We don't develop conventional content because we don't want conventional results. Do you? Give Evolve a call on (09) 3600-120.

