Différence entre l'index et la recherche dans JavaScript

		/* differences between .search() and .indexOf()*/

//If you require regular expression use 
.indexOf()
//otherwise use 
.search()

//other diffrences with example:

//.search() doesn't have starting position
  var text = 'example: this is the example and example'; //bunch of nonsenss
  text.indexOf('example', 9); //9: this is the starting position and its optional
  text.search('example')
Angry puppy