Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public String demandeA() {
- try {
- URL oracle = new URL("http://aenavette.be/Admin/jour.php");
- URLConnection yc = oracle.openConnection();
- BufferedReader in = new BufferedReader(new InputStreamReader(yc.getInputStream()));
- String inputLine;
- while ((inputLine = in.readLine()) != null) {
- Log.d("dl", inputLine.toString());
- }
- in.close();
- return "okay";
- }
- catch (MalformedURLException e) {
- // new URL() failed
- // ...
- return "ouch";
- }
- catch (IOException e) {
- // openConnection() failed
- return "ouch";
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement