Regular Expressions 101

Community Patterns

Query Strings Capture

1

Regular Expression
Python

r"
((?<=[\?\&])foo\=[^\&\#]*)|((?<=[\?\&])foo(?=[\&\#]))|((?<=[\?\&])foo(?!.))
"
g

Description

A solution for capture params or the param=value pair of query strings.

Submitted by Rafael Laurindo - 8 years ago