aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/Text/Pandoc/Readers/HTML.hs8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/Text/Pandoc/Readers/HTML.hs b/src/Text/Pandoc/Readers/HTML.hs
index ed026eb49..ade15349e 100644
--- a/src/Text/Pandoc/Readers/HTML.hs
+++ b/src/Text/Pandoc/Readers/HTML.hs
@@ -164,7 +164,9 @@ anyHtmlTag :: GenParser Char ParserState [Char]
anyHtmlTag = try $ do
char '<'
spaces
- tag <- many1 alphaNum
+ first <- letter
+ rest <- many (alphaNum <|> char ':')
+ let tag = first : rest
attribs <- many htmlAttribute
spaces
ender <- option "" (string "/")
@@ -181,7 +183,9 @@ anyHtmlEndTag = try $ do
spaces
char '/'
spaces
- tag <- many1 alphaNum
+ first <- letter
+ rest <- many (alphaNum <|> char ':')
+ let tag = first : rest
spaces
char '>'
let result = "</" ++ tag ++ ">"