diff options
| author | Andrew Balholm <andybalholm@gmail.com> | 2011-11-11 21:44:01 +1100 |
|---|---|---|
| committer | Nigel Tao <nigeltao@golang.org> | 2011-11-11 21:44:01 +1100 |
| commit | 0a61c846ef36dc43437e37c6494a40b47824124f (patch) | |
| tree | 9b722bf14b12de50ae5dc236da97c505a52275a9 /src/pkg/html/parse.go | |
| parent | 83f61a27d6f1ef053c00b4cc2fd9668fdf354ad8 (diff) | |
| download | go-0a61c846ef36dc43437e37c6494a40b47824124f.tar.xz | |
html: ignore <col> tag outside tables
Pass tests1.dat, test 109:
<table><col><tbody><col><tr><col><td><col></table><col>
| <html>
| <head>
| <body>
| <table>
| <colgroup>
| <col>
| <tbody>
| <colgroup>
| <col>
| <tbody>
| <tr>
| <colgroup>
| <col>
| <tbody>
| <tr>
| <td>
| <colgroup>
| <col>
Also pass test 110:
<table><colgroup><tbody><colgroup><tr><colgroup><td><colgroup></table><colgroup>
R=nigeltao
CC=golang-dev
https://golang.org/cl/5369069
Diffstat (limited to 'src/pkg/html/parse.go')
| -rw-r--r-- | src/pkg/html/parse.go | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/pkg/html/parse.go b/src/pkg/html/parse.go index 6aef7e12ed..e609cce129 100644 --- a/src/pkg/html/parse.go +++ b/src/pkg/html/parse.go @@ -667,6 +667,8 @@ func inBodyIM(p *parser) (insertionMode, bool) { case "image": p.tok.Data = "img" return inBodyIM, false + case "caption", "col", "colgroup", "frame", "head", "tbody", "td", "tfoot", "th", "thead", "tr": + // Ignore the token. default: // TODO. p.addElement(p.tok.Data, p.tok.Attr) |
