Test, validate and match regular expressions
This regex matches URLs with an optional http or https scheme. It validates domain names composed of alphanumeric words and hyphens separated by dots, and optionally includes a path containing word characters, hyphens, spaces, dots, slashes, and query symbols. It is useful for detecting or validating URLs in text, with the global and multiline flags enabling multiple matches across lines.