I am trying to extract a string from within a larger string where it get everything inbetween a : and a ;
:
;
Current
Str = 'MyLongString:StringIWant;'
Desired Output
newStr = 'StringIWant'
You can try this
var mySubString = str.substring( str.indexOf(":") + 1, str.lastIndexOf(";") );
1.4m articles
1.4m replys
5 comments
57.0k users