Other Resources:
0 or more times repetition quantifier *
What is the 0 or more times repetition quantifier? How to use it?
How to write a regular expression using a repetition quantifier to capture all names and values in a URL query string like this: User=Jack&Age=&City=Paris?
✍: FYIcenter.com
![]()
The "0 or more times" repetition quantifier allows us to repeat a pattern unit 1 or more times in the matching process. The "0 or more times" repetition quantifier character is '*' and it needs be placed immediately after the pattern unit. For example:
/^ */ # matches any number of leading space characters / *$/ # matches any number of trailing space characters
The regular expression to capture all names and values in a URL query string is:
([^=]+)=([^&]*)
([^=]+) - repeats 1 more times on any non '=' characters
= - matches the '-'
([^&]*) - repeats any number of times on any non '&' characters
2013-01-26, 0👍, 0💬
Popular Posts:
A free online regular expression test tool that allows to try you regular expression pattern and see...
How to capture the MSN (Microsoft Network) bot entries from Web log file? Here are some Web log file...
All credit card numbers issued by JCB have 3 sets of numbers: JCB cards start with 2131 have 15 digi...
How to capture the Sogou web spider entries from Web log file? Here are some Web log file entries: 1...
All credit card numbers issued by JCB have 3 sets of numbers: JCB cards start with 2131 have 15 digi...