if i use:
socket_read($socket, 1024);
I don't know what type of variable it returns. I want to make it to an int, but i don't know how.
The Server respons only a number (35).
If i echo it, i get 35. If i cast it to "(int)" i get 0. intval returns 0 too.
I have tried to cast it to string, and pick the first letter (3) but it returned 0. Substr doesn't work too.
I want to have an int value, so that i can calculate things with this value. I need an int to calculate the prozentage of this value from another value.
What can i do?
EDIT:
Fixed it in JAVA SERVER SOCKET CODE whith:
PrintWriter out = new PrintWriter(server.getOutputStream());
instead of using
DataOutputStream out = new DataOutputStream(server.getOutputStream());
<p>35</p>or just some invisible to you symbol? Which is parsed by HTML. - sybear