[opencms-dev] OpenCms can't handle CMYK-JPGs?

Florian Heinisch florian.heinisch at 3kraft.com
Mon Nov 16 19:00:14 CET 2009


Hi Roman,

good point, displayresource.jsp is actually modifying the HTTP response (see org.opencms.workplace.commons.CmsDisplayResource line 183):

res.setHeader(
                    CmsRequestUtil.HEADER_CONTENT_DISPOSITION,
                    new StringBuffer("attachment; filename=\"").append(resourceStr).append("\"").toString());

This might be the reason why any browser displays the image when you are logged in. You can also track the HTTP requests/responses with the Live Http Headers plugin for Firefox. Compare the HTTP responses when you are logged in and out, you will see the difference.

Again, to solve this issue I only can encourage you to either automatically convert CMYK-JPGs to RGB from within OpenCMS or to serve ZIP files for image download.

Kind regards,

Florian



On Nov 16, 2009, at 6:47 PM, Roman Uhlig Maxity.de wrote:

> 
> Hi Michael, hi Florian!
> 
> At first I thought that too. But then it would be strange that I can see it in the very same browser when logged in, isn't it? Why would a browser show the image when logged in into OpenCms and does not when not logged in?
> May it be that displayresource.jsp is doing some kind of proxying, so the browser get's a different response?
> 
> Roman
> 
> -----Ursprüngliche Nachricht-----
> Von: opencms-dev-bounces at opencms.org [mailto:opencms-dev-bounces at opencms.org] Im Auftrag von Florian Heinisch
> Gesendet: Montag, 16. November 2009 18:37
> An: The OpenCms mailing list
> Betreff: Re: [opencms-dev] OpenCms can't handle CMYK-JPGs?
> 
> Hi Roman,
> 
> thanks for the URL.
> On MAC OS X 10.6 the image opens perfectly in Safari browser (version 4.0.3) as well as in Firefox (3.5.5).
> On Windows XP the image does not open in MS Internet Explorer (version 7.0.5) but in works in Firefox (3.5.5).
> Again it's the Internet Explorer who is spoiling the party ;-)
> 
> Anyhow, CMYK is not intended for screens as long as these images are intended to get downloaded for printing purposes. Then you still you the possibility to zip these images on the fly with a servlet.
> 
> All the best,
> 
> Florian
> 
> On Nov 16, 2009, at 6:03 PM, Roman Uhlig Maxity.de wrote:
> 
>> 
>> Hi Florian,
>> 
>> thanks for your reply. I put up a test image here:
>> 
>> http://tinyurl.com/ygrpjrp
>> 
>> While I can view it without problems when logged in, it throws a server error message when accessed anonymously, as you can see. At least I think it's a server message, doesn't look like a browser error. Wouldn't a browser error always show up even if I'm logged in? 
>> 
>> As soon as I convert the image to RGB, it works fine. I've tested it with Firefox 2 and IE 8.
>> 
>> Best regards,
>> Roman
>> 
>> 
>> -----Ursprüngliche Nachricht-----
>> Von: opencms-dev-bounces at opencms.org [mailto:opencms-dev-bounces at opencms.org] Im Auftrag von Florian Heinisch
>> Gesendet: Montag, 16. November 2009 17:25
>> An: The OpenCms mailing list
>> Betreff: Re: [opencms-dev] OpenCms can't handle CMYK-JPGs?
>> 
>> Hi Roman,
>> 
>> I worked on a OpenCMS project where CMYK-JPGs were in place. As far as I noticed, OpenCMS handles CMYK-JPGs without problems.
>> However, some browsers did not display the CMYK-JPGs (sorry for being inaccurate, I think it was MS Internet Explorer version 6). So I implemented a Servlet that returns these CMYK-JPGs as a ZIP-files.
>> 
>> What kind of error you get by viewing the CMYK-JPGs when you are logged out? Which OS are you working on and which browser do you use?
>> 
>> Kind regards,
>> 
>> Florian
>> 
>> On Nov 16, 2009, at 11:56 AM, Roman Uhlig Maxity.de wrote:
>> 
>>> 
>>> Last week one of our customers running OpenCms reported that some newly
>>> uploaded images of his website don't display. After investigating that a
>>> bit we realized, that these images where JPG's with CMYK color space.
>>> They display well in any browser, but OpenCms seems not able to handle
>>> them. The strange thing is: if you are logged in into the workplace they
>>> display fine. As soon as you call their URI from outside (no matter if
>>> it's the exported resource or not), it fails.
>>> 
>>> Is that a known problem or should I file a bug about it?
>>> 
>>> Thanks in advance,
>>> Roman
>>> 
>>> _______________________________________________
>>> This mail is sent to you from the opencms-dev mailing list
>>> To change your list options, or to unsubscribe from the list, please visit
>>> http://lists.opencms.org/mailman/listinfo/opencms-dev
>> 
>> 
>> _______________________________________________
>> This mail is sent to you from the opencms-dev mailing list
>> To change your list options, or to unsubscribe from the list, please visit
>> http://lists.opencms.org/mailman/listinfo/opencms-dev
>> 
>> _______________________________________________
>> This mail is sent to you from the opencms-dev mailing list
>> To change your list options, or to unsubscribe from the list, please visit
>> http://lists.opencms.org/mailman/listinfo/opencms-dev
> 
> 
> _______________________________________________
> This mail is sent to you from the opencms-dev mailing list
> To change your list options, or to unsubscribe from the list, please visit
> http://lists.opencms.org/mailman/listinfo/opencms-dev
> 
> _______________________________________________
> This mail is sent to you from the opencms-dev mailing list
> To change your list options, or to unsubscribe from the list, please visit
> http://lists.opencms.org/mailman/listinfo/opencms-dev




More information about the opencms-dev mailing list