"You don't know where your shadow will fall", Somebody.
PHP Query String Class
This class can manipulate query strings used in HTTP requests that are used to pass arguments and values to page scripts.
It can get and set argument values, delete arguments and count the number of ocurrences in a given query string.
Download source code from:
http://www.phpclasses.org/browse/package/2378.html
Or from this blog: