note 19028 added to ref.java

From: Date: Wed, 13 Feb 2002 17:38:23 +0000
Subject: note 19028 added to ref.java
Groups: php.notes 
Request: Send a blank email to php-notes+get-26565@lists.php.net to get a copy of this message
Java/php bridge? I used printwriter to send data from a java applet to a php document. URL url = new URL("http://www.blabla.com/bla/bla.php"); URLConnection connection = url.openConnection(); connection.setDoOutput(true); PrintWriter out = new PrintWriter(connection.getOutputStream()); out.println(var1); out.println(var2); out.println(var3); out.println(var4); out.flush(); out.close(); BufferedReader in = new BufferedReader(new InputStreamReader(connection.getInputStream())); String inputLine; while ((inputLine = in.readLine()) != null) System.out.println(inputLine+"\r\n"); in.close(); The problem is that java puts all the data into var1 and doesn't send var2,var3,var4. -----in bla.php $var1; //contains all the data. // $var2,3,4 doesn't exist How can i code the java applet to send var2,var3 and var4? -- http://www.php.net/manual/en/ref.java.php http://master.php.net/manage/user-notes.php?action=edit+19028 http://master.php.net/manage/user-notes.php?action=delete+19028 http://master.php.net/manage/user-notes.php?action=reject+19028

« previous php.notes (#26565) next »