[Webkit-unassigned] [Bug 24904] New: Add a defaultMimeType to ResourceRequest

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Mar 27 16:14:33 PDT 2009


https://bugs.webkit.org/show_bug.cgi?id=24904

           Summary: Add a defaultMimeType to ResourceRequest
           Product: WebKit
           Version: 528+ (Nightly build)
          Platform: All
               URL: https://myrewardzone.bestbuy.com/
        OS/Version: All
            Status: NEW
          Severity: Normal
          Priority: P2
         Component: CSS
        AssignedTo: webkit-unassigned at lists.webkit.org
        ReportedBy: abarth at webkit.org
                CC: eroman at chromium.org


In standards mode, we requires that that stylesheets loaded via a link tag have
the proper MIME type, "text/css."  Apparently, this is required to pass ACID3. 
Unfortunately, a number of Web sites supply stylesheets to standards mode pages
without specifying a Content-Type header.  These pages work fine in Safari and
Firefox, but fail to load their stylesheets in Chromium because Chromium sniffs
their MIME type as "text/plain."

There are a couple of solutions to this problem:

1) Accept text/plain stylesheets in standards mode.

2) Change the content sniffer to guess text/css for URLs that end in ".css"

3) Provide a hint from WebCore to the content sniffer that we're expecting a
text/css resource.

I think options (2) and (3) are workable.  Wan-Teh debugged Firefox's handling
of this situation and determined that they take approach (3).  This is
observable because they accept a stylesheet named style.foo in standards mode
even if the stylesheet lacks a Content-Type header.  Without access to Safari's
source code, we were unable to determine how Safari handles this case.

I recommend that we provide a MIME type hint to the network layer when loading
CSS files so Chromium can perfectly match Firefox's behavior here.

Patch forthcoming.


-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.



More information about the webkit-unassigned mailing list