adding support for url parameters in redirect