As we transition to the new Hyland Community, some post links may be temporarily disrupted as we finalize redirects. We apologize for the inconvenience and are working to resolve this as quickly as possible. Details.
//Getting the ticket String url = "http://myserver:8080/alfresco/upload/uploadinghttp.pdf?ticket='+ticket; URL server = new URL(url); HttpURLConnection connection = (HttpURLConnection)server.openConnection(); connection.setRequestMethod("PUT"); connection.setDoOutput(true); connection.setDoInput(true); connection.connect(); OutputStream cosa = connection.getOutputStream(); cosa.write(aos.toByteArray()); cosa.flush(); System.out.println("code: "+connection.getResponseCode()); InputStream is = connection.getInputStream(); int c; while ((c=is.read())!=-1){ System.err.print((char)c); } //End session