Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

javascript get string between two parentheses

var regExp = /(([^)]+))/;
var matches = regExp.exec("I expect five hundred dollars ($500).");

//matches[1] contains the value between the parentheses
console.log(matches[1]);
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #javascript #string #parentheses
ADD COMMENT
Topic
Name
6+1 =