added queryString method to get last query string