4f0b60e62a80c76fd35eb402b435544532f8e2c1
[citadel.git] / ctdlphp / ctdlprotocol.php
1 <?PHP
2
3 function test_for_echo() {
4
5         global $clientsocket, $session;
6
7         $command = "ECHO Video vertigo ... test for echo.\n";
8
9         echo "Trying echo ... session name is ", $session, "<BR>\n";
10         flush();
11         echo "Writing...<BR>\n";
12         flush();
13         // fwrite($clientsocket, $command, strlen($command));
14         fwrite($clientsocket, $command);
15         echo "Reading...<BR>\n";
16         flush();
17         $response = fgets($clientsocket, 4096);
18         echo $response, "<BR>";
19         flush();
20 }
21
22 ?>