added Window function redirect to easily redirect user