[xwiki-devs] Why is Utils#getRedirect() returning absolute URLs?
Hi devs, HttpServletResponse#sendRedirect() accepts relative URLs. Do you know or remember why we explicitly generate absolute URLs in Utils#getRedirect() which is used in lots of places in old core to get the redirect URL. There is no comment to explain why we treat redirect URLs different than the rest of the URLs we generate (which are relative). I would like to change Utils#getRedirect() to generate URLs relative to the servlet container root as it should. Here's the change https://github.com/xwiki/xwiki-platform/commit/029ece1585ad03fd6402c12446be4... (on an old branch). Thanks, Marius
Big +1. Seems to me that I should have changed it already with http://markmail.org/message/et2p7ndlcyt2lnql but did not seen it. On Mon, Jan 21, 2013 at 6:06 PM, Marius Dumitru Florea <[email protected]> wrote:
Hi devs,
HttpServletResponse#sendRedirect() accepts relative URLs. Do you know or remember why we explicitly generate absolute URLs in Utils#getRedirect() which is used in lots of places in old core to get the redirect URL. There is no comment to explain why we treat redirect URLs different than the rest of the URLs we generate (which are relative).
I would like to change Utils#getRedirect() to generate URLs relative to the servlet container root as it should. Here's the change https://github.com/xwiki/xwiki-platform/commit/029ece1585ad03fd6402c12446be4... (on an old branch).
Thanks, Marius _______________________________________________ devs mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/devs
-- Thomas Mortagne
participants (2)
-
Marius Dumitru Florea -
Thomas Mortagne