content-type-000

text/css content type

WeasyPrint

This browser

Flags
http
Assertion
A stylesheet sent as text/plain should not be interpreted by user agents as CSS. It should instead be ignored.

Source

 1 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
 2 <html>
 3 
 4  <head>
 5  
 6   <title>CSS Test: text/css content type</title>
 7   
 8   <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/">
 9   <link rel="author" title="David Hammond" href="http://www.webdevout.net/contact">
10   <link rel="help" href="http://www.w3.org/TR/CSS21/conform.html#text-css">
11   <meta content="http" name="flags">
12   <meta content="A stylesheet sent as text/plain should not be interpreted by user agents as CSS. It should instead be ignored." name="assert">
13 
14   <style type="text/css">
15   div
16   {
17   background-color: lime;
18   font-size: 2em;
19   }
20   </style>
21 
22   <link href="support/plaintext.css" rel="stylesheet" type="text/css">
23   <!--
24   in .htaccess
25   <Files plaintext.css>
26   ForceType text/plain
27   </Files>
28   -->
29 
30  </head>
31 
32  <body>
33 
34   <p>Test passes if the background of the text sample is bright green. There should be <strong>no red</strong>.</p>
35 
36   <div>Text sample</div>
37 
38  </body>
39 </html>