REGEX-Escape for: ^\\s*[+-]?([0-9]*[.])?[0-9]+\\s*$

Your Input:
Result, the escaped string:
\^\\\\s\*\[\+\-\]\?\(\[0\-9\]\*\[\.\]\)\?\[0\-9\]\+\\\\s\*\$


Ads

What must the escaping look like for:
^\\s*[+-]?([0-9]*[.])?[0-9]+\\s*$

The excaped text for use in a regex is:

\^\\\\s\*\[\+\-\]\?\(\[0\-9\]\*\[\.\]\)\?\[0\-9\]\+\\\\s\*\$


Ads