Regular Expressions 101

Community Patterns

Community Library Entry

0

Regular Expression
ECMAScript (JavaScript)

/
(([\W\w]*)(apps)(-?)([\w]{0,2})(.[\W\w]*))
/

Description

Tokenize a HostName for optional string values. Good for testing whether you are in np, qa, qp, or production environments.

Submitted by Matthew Ledbetter - 9 years ago