Bug 32837 - Explicit Content-Type value "text/css" changed to "text/html, text/css"
Summary: Explicit Content-Type value "text/css" changed to "text/html, text/css"
Status: RESOLVED INVALID
Alias: None
Product: WebKit
Classification: Unclassified
Component: Layout and Rendering (show other bugs)
Version: 528+ (Nightly build)
Hardware: PC Windows XP
: P2 Normal
Assignee: Nobody
URL: http://demo.webplusshop.com/showmedia...
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2009-12-21 13:11 PST by JamesVG
Modified: 2009-12-21 13:59 PST (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description JamesVG 2009-12-21 13:11:51 PST
The referenced URL of a css file sends an explicit Content-Type "text/css" that is interpreted by WebKit as "text/html, text/css" by r52427. This error seems to prevent pages from using the stylesheet.
Comment 1 Mark Rowe (bdash) 2009-12-21 13:40:06 PST
The server is sending two Content-Type headers:

Content-Type: text/html
Content-Type: text/css

RFC 2616 has this to say about the presence of multiple headers with the same name:

> Multiple message-header fields with the same field-name MAY be present
> in a message if and only if the entire field-value for that header field
> is defined as a comma-separated list [i.e., #(values)].

Since Content-Type’s value isn’t defined to be a comma-separated list the response headers for this resource appear to be invalid.  That said, we appear to be handling these invalid headers in a different manner than how Firefox handles them.  We should look at matching their behavior here.

In the mean time the website could achieve the result they’re after by sending valid response headers.
Comment 2 Mark Rowe (bdash) 2009-12-21 13:59:17 PST
This aspect of HTTP is handled by the underlying HTTP stack used by WebKit, in this case CFNetwork.  CFNetwork itself is not part of WebKit so this bug needs to be tracked in Radar.  It’s been written up as <rdar://problem/7209476>.  Thanks for the report.