Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

regex match number javascript

str = "hello123!"	
str.match(/(d+)/)[1]	//Best way to find first matching number in string ;)
 
PREVIOUS NEXT
Tagged: #regex #match #number #javascript
ADD COMMENT
Topic
Name
2+3 =