I have a text string, which can be any number of characters that I would like to add at the end of the order number. Then I can pull out the order number when I need to use it again. Since there is a possibility that the number is of variable length, I would like to make a regular expression that will catch everything after the = sign in the string ?order_num=
So the whole line will be
"aijfoi aodsifj adofija afdoiajd?order_num=3216545"
I tried using the regex generator online, but no luck. Can someone please help me with extracting the number at the end and putting them in a variable and something that puts what comes before ?order_num=203823 in its own variable.
I will send my own attempts, but I foresee failure and confusion.
javascript regex
1252748
source share