Correctly escape character in HTML weaving

This commit is contained in:
Denis Merigoux 2022-08-12 09:51:43 +02:00
parent ef269df553
commit c6e448a9b7
No known key found for this signature in database
GPG Key ID: EE99DCFA365C3EE3

View File

@ -161,7 +161,7 @@ let pygmentize_code (c : string Marked.pos) (language : C.backend_lang) : string
let sanitize_html_href str =
str
|> String_common.to_ascii
|> R.substitute ~rex:(R.regexp "[' '°]") ~subst:(function _ -> "%20")
|> R.substitute ~rex:(R.regexp "[' '°\"]") ~subst:(function _ -> "%20")
let rec law_structure_to_html
(language : C.backend_lang)