substr in javascript


Syntax

string.substr(start,length)

ParameterDescription
startRequired. The index where to start the extraction. First character is at index 0
lengthOptional. The number of characters to extract. If omitted, it extracts the rest of the string




Example

Example

Extract characters from a string:
The output of the code above will be:
v
vR



Popular posts from this blog

CVR Nummer : Register CVR Number for Denmark Generate and Test Online

Bing Homepage Quiz: Fun, Win Rewards, and Brain Teasers

How To Iterate Dictionary Object