diff options
author | Alon Zakai <alonzakai@gmail.com> | 2012-03-06 10:34:19 -0800 |
---|---|---|
committer | Alon Zakai <alonzakai@gmail.com> | 2012-03-06 10:34:19 -0800 |
commit | ac6876fb82b553ed6a5427b8b5abbe6ecb4ef34a (patch) | |
tree | 69b53e99462483ff619c8e3880fb3e22879fc12a /src/shell.html | |
parent | 89642b135f2a6852011b718ff5058ea8e032bc13 (diff) |
escape & in html
Diffstat (limited to 'src/shell.html')
-rw-r--r-- | src/shell.html | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/shell.html b/src/shell.html index a41086b9..2f34ace3 100644 --- a/src/shell.html +++ b/src/shell.html @@ -19,6 +19,7 @@ print: (function() { var element = document.getElementById('output'); return function(text) { + text = text.replace(/&/g, "&"); text = text.replace(/</g, "<"); text = text.replace(/>/g, ">"); text = text.replace('\n', '<br>', 'g'); |