added suppport for urls with ? in the path