/** * OpenCms servlet POST request handling method, * will just call {@link #doGet(HttpServletRequest, HttpServletResponse)}.<p> * * @see javax.servlet.http.HttpServlet#doPost(javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse) */ @Override public void doPost(HttpServletRequest req, HttpServletResponse res) throws IOException, ServletException { doGet(req, res); }
init(getServletConfig()); } else { if (path.startsWith(HANDLE_PATH)) { invokeHandler(req, res); } else if (path.endsWith(HANDLE_GWT)) { OpenCmsCore.getInstance().invokeGwtService(serviceName, req, res, getServletConfig()); } else {
/** * Manages requests to internal OpenCms request handlers.<p> * * @param req the current request * @param res the current response * @throws ServletException in case an error occurs * @throws ServletException in case an error occurs * @throws IOException in case an error occurs */ protected void invokeHandler(HttpServletRequest req, HttpServletResponse res) throws IOException, ServletException { String name = OpenCmsCore.getInstance().getPathInfo(req).substring(HANDLE_PATH.length()); I_CmsRequestHandler handler = OpenCmsCore.getInstance().getRequestHandler(name); if ((handler == null) && name.contains("/")) { // if the name contains a '/', also check for handlers matching the first path fragment only name = name.substring(0, name.indexOf("/")); handler = OpenCmsCore.getInstance().getRequestHandler(name); } if (handler != null) { handler.handle(req, res, name); } else { openErrorHandler(req, res, HttpServletResponse.SC_INTERNAL_SERVER_ERROR); } }
if (!tryCustomErrorPage(cms, req, res, errorCode)) { cms.getRequestContext().setUri(handlerUri); cms.getRequestContext().setSecureRequest(OpenCms.getSiteManager().usesSecureSite(req));
if (site.getErrorPage() != null) { String rootPath = site.getErrorPage(); if (loadCustomErrorPage(cms, req, res, rootPath)) { return true; if (loadCustomErrorPage(cms, req, res, rootPath)) { return true;
init(getServletConfig()); } else { if (path.startsWith(HANDLE_PATH)) { invokeHandler(req, res); } else {
/** * Manages requests to internal OpenCms request handlers.<p> * * @param req the current request * @param res the current response * @throws ServletException in case an error occurs * @throws ServletException in case an error occurs * @throws IOException in case an error occurs */ protected void invokeHandler(HttpServletRequest req, HttpServletResponse res) throws IOException, ServletException { String name = OpenCmsCore.getInstance().getPathInfo(req).substring(HANDLE_PATH.length()); I_CmsRequestHandler handler = OpenCmsCore.getInstance().getRequestHandler(name); if (handler != null) { handler.handle(req, res, name); } else { openErrorHandler(req, res, HttpServletResponse.SC_INTERNAL_SERVER_ERROR); } }
/** * OpenCms servlet POST request handling method, * will just call {@link #doGet(HttpServletRequest, HttpServletResponse)}.<p> * * @see javax.servlet.http.HttpServlet#doPost(javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse) */ @Override public void doPost(HttpServletRequest req, HttpServletResponse res) throws IOException, ServletException { doGet(req, res); }
LOG.warn(Messages.get().getBundle().key(Messages.LOG_ERROR_EXPORT_1, exportData), t); openErrorHandler(req, res, errorCode); openErrorHandler(req, res, errorCode); openErrorHandler(req, res, errorCode);
super.doGet(req, res); } else {
LOG.warn(Messages.get().getBundle().key(Messages.LOG_ERROR_EXPORT_1, exportData), t); openErrorHandler(req, res, errorCode); openErrorHandler(req, res, errorCode); openErrorHandler(req, res, errorCode);
super.doGet(req, res); } else {