mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2024-06-18 11:29:55 +00:00
Add nbsp handling to htmlDecode
This commit is contained in:
parent
4b000fac72
commit
b5d2b79a37
|
@ -207,10 +207,10 @@ $tw.utils.deepDefaults = function(object /*, sourceObjectList */) {
|
||||||
};
|
};
|
||||||
|
|
||||||
/*
|
/*
|
||||||
Convert "&" to &, "<" to <, ">" to > and """ to "
|
Convert "&" to &, " " to nbsp, "<" to <, ">" to > and """ to "
|
||||||
*/
|
*/
|
||||||
$tw.utils.htmlDecode = function(s) {
|
$tw.utils.htmlDecode = function(s) {
|
||||||
return s.toString().replace(/</mg,"<").replace(/>/mg,">").replace(/"/mg,"\"").replace(/&/mg,"&");
|
return s.toString().replace(/</mg,"<").replace(/ /mg,"\x40").replace(/>/mg,">").replace(/"/mg,"\"").replace(/&/mg,"&");
|
||||||
};
|
};
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
Loading…
Reference in New Issue
Block a user