how to remove leading and trailing spaces in javascript code example
Example: javascript trim
var str=" I have outer spaces ";
var cleanStr=str.trim();//trim() returns string with outer spaces removed
var str=" I have outer spaces ";
var cleanStr=str.trim();//trim() returns string with outer spaces removed