public static String getRequestURLBaseWithoutProtocol(HttpServletRequest req)
	{
		return req.getServerName() +
				(req.getServerPort() != 80 ? ":" + req.getServerPort() : "");
	}
public static String getRequestURLBaseWithoutProtocol ( HttpServletRequest req ) { return req . getServerName ( ) + ( req . getServerPort ( ) != 80 ? ":" + req . getServerPort ( ) : "" ) ; }
Gets a clean base url without the path from the current request.

@param req
@return