Javascript String contains(str, index)

Description

Javascript String contains(str, index)


/**//from   w  ww . j  ava2  s  .  co m
 * String Prototype Methods
 */

// String Contains
String.prototype.contains = function(str, index) {
 return (this.indexOf(str, index) !== -1) ? true : false;
}



PreviousNext

Related