JSPManager.showJSP(request, response, "/dspace-admin/edit-community.jsp");
JSPManager.showJSP(request, response, "/tools/edit-community.jsp");
    private void processUploadLogo(Context context,        HttpServletRequest request,        HttpServletResponse response)        throws ServletException, IOException, SQLException, AuthorizeException    {        // Wrap multipart request to get the submission info        FileUploadRequest wrapper = new FileUploadRequest(request);        Community community = Community.find(context,            UIUtil.getIntParameter(wrapper, "community_id"));        Collection collection = Collection.find(context,            UIUtil.getIntParameter(wrapper, "collection_id"));        File temp = wrapper.getFile("file");        // Read the temp file as logo        InputStream is = new BufferedInputStream(new FileInputStream(            temp));        Bitstream logoBS;        if (collection == null)        {            logoBS = community.setLogo(is);        }        else        {            logoBS = collection.setLogo(is);        }        // Strip all but the last filename.  It would be nice        // to know which OS the file came from.        String noPath = wrapper.getFilesystemName("file");        while (noPath.indexOf('/') > -1)        {            noPath = noPath.substring(                        noPath.indexOf('/') + 1);        }        while (noPath.indexOf('\\') > -1)        {            noPath = noPath.substring(                        noPath.indexOf('\\') + 1);        }        logoBS.setName(noPath);        logoBS.setSource(wrapper.getFilesystemName("file"));        // Identify the format        BitstreamFormat bf = FormatIdentifier.guessFormat(context, logoBS);        logoBS.setFormat(bf);        logoBS.update();         if (collection == null)        {            community.update();            // Show community edit page            request.setAttribute("community", community);            JSPManager.showJSP(request, response, "/dspace-admin/edit-community.jsp");        }        else        {            collection.update();            // Show collection edit page                        request.setAttribute("collection", collection);            request.setAttribute("community", community);            JSPManager.showJSP(request, response, "/dspace-admin/edit-collection.jsp");        }        // Remove temp file        temp.delete();        // Update DB        context.complete();    }