added support for query strings