var myString = 'Guy Maimon'
Sending a query of | will return | explaination |
---|---|---|
|
10 | Returns the length of thestring |
|
y | Returns a specific char from a string (0 based) |
|
6 |
Returns where the typed string starts from if not found, will return -1 |
|
TRUE | Returns TRUE if exists somewhere otherwise Returns FALSE |
|
It's There |
if(myString.indexOf('test') !== -1) Returns Ture if the exists in the string if not found, will return -1 |
|
guy maimon | converst all text to lower case |
|
GUY MAIMON | converst all text to upper case |
|
imon | Returns string after cutting # chars does not change the variable |
|
im | Returns string after cutting #1 chars Returns all the chars until #2 does not change the variable |