Receiving Server Initproblem Connection
If you cannot connect to the database by going to phpMyAdmin, then you know it is something with your server. It does not necessarily means that your MySQL server is down. It could mean that your user does not have sufficient permission. In our case, our MySQL server was running. All other sites on the servers were working fine except for. In this state the client can still receive data from the server but will no longer accept data from its local application to be sent to the server. — ESTABLISHED. Client Close Step #1 Receive and Step #2 Transmit: The server receives the client's FIN. It sends an ACK to acknowledge the FIN. The server must wait for the application using it to be told the other end is closing, so the application here can finish what it is doing.
I have a homework to build an application which will send and receive simple string between server and client. I know how to establish connection, but don't know how to send and receive string. This is my code :
5 Answers
The following code send and recieve the current date and time from and to the server
//The following code is for the server application:
//this is the code for the client
Nudier MenaNudier MenaIn addition to @Nudier Mena answer, keep a while loop to keep the server in listening mode. So that we can have multiple instance of client connected.