jquery - Get integer from javascript string -


i've strings values like:

share__43 share__153 share share_section

how integer values 43 or 153?

example, using single string

var regex = /\d+/; var str = "share__43"; alert (str.match(regex )); 

demo


Comments

Popular posts from this blog

java.util.scanner - How to read and add only numbers to array from a text file -

rewrite - Trouble with Wordpress multiple custom querystrings -