Skip to main content
replaced http://stackoverflow.com/ with https://stackoverflow.com/
Source Link
URL Rewriter Bot
URL Rewriter Bot

I understand how to retrieve digits from a string after reading Regex using javascript to return just numbersRegex using javascript to return just numbers

I am wondering if I can validate my input at the same time. While implementing an LMS, I am looking for input strings matching "com.interactions.*n*.objectives.*m*.id", where n & m are integers.

In one regex function, can I retrieve the digits n & m ONLY IF my input string matches the pattern above? Or do I need to first validate the input string, and then pull the digits out afterwards?

I understand how to retrieve digits from a string after reading Regex using javascript to return just numbers

I am wondering if I can validate my input at the same time. While implementing an LMS, I am looking for input strings matching "com.interactions.*n*.objectives.*m*.id", where n & m are integers.

In one regex function, can I retrieve the digits n & m ONLY IF my input string matches the pattern above? Or do I need to first validate the input string, and then pull the digits out afterwards?

I understand how to retrieve digits from a string after reading Regex using javascript to return just numbers

I am wondering if I can validate my input at the same time. While implementing an LMS, I am looking for input strings matching "com.interactions.*n*.objectives.*m*.id", where n & m are integers.

In one regex function, can I retrieve the digits n & m ONLY IF my input string matches the pattern above? Or do I need to first validate the input string, and then pull the digits out afterwards?

added 2 characters in body
Source Link
Dalorzo
  • 20k
  • 7
  • 57
  • 102

I understand how to retrieve digits from a string after reading Regex using javascript to return just numbers

I am wondering if I can validate my input at the same time. While implementing an LMS, I am looking for input strings matching "com.interactions.n.objectives.m.id""com.interactions.*n*.objectives.*m*.id", where n & m are integers.

In one regex function, can I retrieve the digits n & m ONLY IF my input string matches the pattern above? Or do I need to first validate the input string, and then pull the digits out afterwards?

I understand how to retrieve digits from a string after reading Regex using javascript to return just numbers

I am wondering if I can validate my input at the same time. While implementing an LMS, I am looking for input strings matching "com.interactions.n.objectives.m.id", where n & m are integers.

In one regex function, can I retrieve the digits n & m ONLY IF my input string matches the pattern above? Or do I need to first validate the input string, and then pull the digits out afterwards?

I understand how to retrieve digits from a string after reading Regex using javascript to return just numbers

I am wondering if I can validate my input at the same time. While implementing an LMS, I am looking for input strings matching "com.interactions.*n*.objectives.*m*.id", where n & m are integers.

In one regex function, can I retrieve the digits n & m ONLY IF my input string matches the pattern above? Or do I need to first validate the input string, and then pull the digits out afterwards?

Source Link
Chicowitz
  • 6k
  • 5
  • 34
  • 38

Javascript: use regex to find digits in the matching string

I understand how to retrieve digits from a string after reading Regex using javascript to return just numbers

I am wondering if I can validate my input at the same time. While implementing an LMS, I am looking for input strings matching "com.interactions.n.objectives.m.id", where n & m are integers.

In one regex function, can I retrieve the digits n & m ONLY IF my input string matches the pattern above? Or do I need to first validate the input string, and then pull the digits out afterwards?