15. april 2004 - 14:54
Der er
5 kommentarer
Jeg vil poste xml fra mit java program til en asp side på en iis
Jeg vil poste xml fra mit java program til en asp side på en iis men får følgende fejl. 15-04-2004 14:46:56 Fejl i URL 15-04-2004 14:46:56 no protocol: xml_os_sync_run_lev.asp 15-04-2004 14:46:56 Error in postRequest(): Secure Service Required XMLEksport - sendPost - 1 Hvorfor?
Annonceindlæg fra Computerworld
17. april 2004 - 21:41
#4
Jeg har lige fundet en stump kode fra noget jeg rodede med for et stykke tid siden. private static DataInputStream openAndPost (URL url, String content) throws IOException { URLConnection uc; uc = url.openConnection(); uc.setDoInput (true); if (content != null && content.length () > 0) { uc.setDoOutput (true); DataOutputStream o = new DataOutputStream (uc.getOutputStream()); o.writeBytes (content); o.flush(); o.close(); } else { uc.setDoOutput (false); } return new DataInputStream (uc.getInputStream()); }