Regex to get value of URL parameter?
Posted
by stef
on Stack Overflow
See other posts from Stack Overflow
or by stef
Published on 2010-05-30T21:59:10Z
Indexed on
2010/05/30
22:02 UTC
Read the original article
Hit count: 254
In a url like the one below, I'd like to get the value of ProdId. The URL format will always be consistent, as will the parameter name, but the length of the value may change. It will always be numeric.
http://www.site.com/page.php?ProdId=2683322&xpage=2
Using PHP what's the fastest way to get it (I'll be processing 10,000's so speed is an issue) ?
© Stack Overflow or respective owner