I'm trying to display device's list in other web site. This is my JAVA code:
Code: StringBuffer result=new StringBuffer(); try{ //set URL URL url = new URL("http://zenuser:zenpassw...@192.168.25.129:8080/zport/dmd/Devices/deviceList"); //make connection URLConnection urlc = url.openConnection(); //use post mode urlc.setDoOutput(true); urlc.setAllowUserInteraction(false); //send query PrintStream ps; ps = new PrintStream(urlc.getOutputStream()); ps.close(); //get result BufferedReader br = new BufferedReader(new InputStreamReader(urlc.getInputStream())); String l = null; while ((l=br.readLine())!=null) { result.append(l); } br.close(); } catch (IOException e) { result.append("IOException: "+ e.getMessage()); } Any help? Thanks -------------------- m2f -------------------- Read this topic online here: http://forums.zenoss.com/viewtopic.php?p=38593#38593 -------------------- m2f -------------------- _______________________________________________ zenoss-users mailing list zenoss-users@zenoss.org http://lists.zenoss.org/mailman/listinfo/zenoss-users