/ Published in: JavaScript
like PHP function htmlEntities
Expand |
Embed | Plain Text
function htmlEntities(str) { return String(str).replace(/&/g, '&').replace(/</g, '<').replace(/>/g, '>').replace(/"/g, '"'); }
You need to login to post a comment.
