sulu: HtmlMarkupParser misbehaving

Q A
Bug? yes
New Feature? no
Sulu Version 6f863a9

We’d like to have some previews of contents (e.g. images) inside the editor. Developing this we found out, that there are some issues in the HtmlMarkupParser.

See https://regex101.com/r/iG6nO0/4 . There I’ve added some cases I think should be possible.

Use cases

  • Previews in Editor (Like images, oembed, …)
  • Internal links on Images
  • Own tags linking to something

About this issue

  • Original URL
  • State: closed
  • Created 8 years ago
  • Comments: 15 (15 by maintainers)

Most upvoted comments

Would the performance penalty ever noticeable compared to secure (in terms of bugs) HTML parsing with XPath?

http://stackoverflow.com/a/1732454/2084176 :trollface:

Every time you attempt to parse HTML with regular expressions, the unholy child weeps the blood of virgins, and Russian hackers pwn your webapp. Parsing HTML with regex summons tainted souls into the realm of the living. HTML and regex go together like love, marriage, and ritual infanticide.