Mavengers
Developer's Blog
Sunday, March 6, 2016
Jquery update character from string using index or character at postion
setCharAt: function (str, index, chr) {
if (index > str.length - 1) return str;
return str.substr(0, index) + chr + str.substr(index + 1);
}
No comments:
Post a Comment
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment