NOTE: The current preferred location for bug reports is the GitHub issue tracker.
Bug 937 - Duplication of br-elements
Duplication of br-elements
Status: RESOLVED INTENTIONAL
Product: Validator.nu
Classification: Unclassified
Component: HTML parser
HEAD
All All
: P2 normal
Assigned To: Nobody
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2012-08-10 01:38 CEST by Niels Hoogeveen
Modified: 2012-09-21 15:08 CEST (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Niels Hoogeveen 2012-08-10 01:38:23 CEST
When parsing the String "<div>Hello<br></br></div>", it leads to multiplication of the br-element: "<div>Hello<br></br><br></br></div>".
Comment 1 Michael[tm] Smith 2012-08-10 14:46:19 CEST
I can't reproduce this. What I get is the same as what browsers do, which is "<div>Hello<br><br>", as expected -- with parse-error message saying, 'End tag “br”.'

  http://html5.validator.nu/parsetree/?parser=html5&content=%3Cdiv%3EHello%3Cbr%3E%3C%2Fbr%3E%3C%2Fdiv%3E&submit=Print+Tree
Comment 2 Henri Sivonen 2012-09-21 15:08:11 CEST
Resolving per comment 1. Indeed </br> behaves like <br> per spec for compatibility with legacy oddities.