Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

remover o primeiro caracter de uma string javascript

var string1 = "foobar";
var string2 = string1.substr(1);
console.log(string2); // shows "oobar"

var string = "//www.pipi.com";
while(string.charAt(0) === '/') { //take character position 0
   string = string.substr(1);
}
 
PREVIOUS NEXT
Tagged: #remover #primeiro #caracter #de #uma #string #javascript
ADD COMMENT
Topic
Name
2+1 =