W3C home > Mailing lists > Public > public-html@w3.org > February 2008

<table><select><td> parsing

From: Philip Taylor <pjt47@cam.ac.uk>
Date: Sun, 10 Feb 2008 00:30:53 +0000
Message-ID: <47AE45BD.1070909@cam.ac.uk>
To: HTML WG <public-html@w3.org>

Consider the document:

<!DOCTYPE html>
<table><td>x</td> <select><option>a<option>b <td>y</td>

In IE6, Firefox 2, Safari 3 and Opera 9.2, this is rendered as a select 
box with options "a" and "b" followed by a table containing cells "x" 
and "y".

HTML5 currently parses this as:

| <!DOCTYPE html>
| <html>
|   <head>
|   <body>
|     <select>
|       <option>
|         "a"
|       <option>
|         "b y"
|     <table>
|       <tbody>
|         <tr>
|           <td>
|             "x"
|           " "

(<http://parsetree.validator.nu/?doc=http://philip.html5.org/misc/fostered-select.html>) 
and does not handle the second cell in a compatible way.

(This happens because the <select> changes the insertion mode from "in 
table" to "in select", and <td> is ignored in that mode.)

-- 
Philip Taylor
pjt47@cam.ac.uk
Received on Sunday, 10 February 2008 00:31:11 UTC

This archive was generated by hypermail 2.3.1 : Monday, 29 September 2014 09:38:52 UTC