SyntaxFix
Write A Post
Hire A Developer
Questions
Here's another way of doing it:
function isPalin(str) { str = str.replace(/\W/g,'').toLowerCase(); return(str==str.split('').reverse().join('')); }