I am making a java program that runs on a local server.
The server accepts the request from the client using PHP.
<?php $file = fopen('temp.txt', 'a+'); $a=explode(':',$_GET['content']); fwrite($file,$a[0].':'.$a[1]. '\n'); fclose($file); ?>
Now I have a temp.txt file on the local server.
A Java program should open a file that is read line by line, and each of them should be split / blown ":" (There is only one ":" in a line)
I tried differently, but could not, just like PHP breaks a string.
Is it possible to use the same / similar break function in JAVA.
java php
user2456813
source share