Regular Expressions 101

Community Patterns

Select Base Url without standard ports

0

Regular Expression
ECMAScript (JavaScript)

/
(https:\/\/provider\.shsp\.swisscom\.com(?:(?!(:443|:80)(\/|\s))(?:(?::)(\d*)))*(?!:443|:80))+((?!\/stable(?=\/))(\/latest(?=\/))?)*
/
g

Description

1 Part baseurl (req) 2 Part Port (optional) but not 443 or 80 3 Part /latest (optional)

(req)(:opt(!443 or 80))(opt)

Submitted by anonymous - 7 years ago