Escape HTML special characters ``&<>`` and quotes ``'"``.
(string)
| 3487 | |
| 3488 | |
| 3489 | def html_escape(string): |
| 3490 | """ Escape HTML special characters ``&<>`` and quotes ``'"``. """ |
| 3491 | return string.replace('&', '&').replace('<', '<').replace('>', '>')\ |
| 3492 | .replace('"', '"').replace("'", ''') |
| 3493 | |
| 3494 | |
| 3495 | def html_quote(string): |
no test coverage detected
searching dependent graphs…