hi guys i have a problem
i use the code bellow:
$host = "192.168.1.2";
$port = 1234;
$socket = socket_create(AF_INET, SOCK_STREAM, 0) or die("Could not create socket\n");
$result = socket_bind($socket, $host, $port) or die("Could not bind to socket\n");
$result = socket_listen($socket, 3) or die("Could not set up socket listener\n");
$spawn = socket_accept($socket) or die("Could not accept incoming connection\n");
$input = socket_read($spawn, 1024) or die("Could not read input\n");
$input = trim($input);
$output = strrev($input) . "\n";
socket_write($spawn, $output, strlen ($output)) or die("Could not write output\n");
and i get
Fatal error: Call to undefined function: bind() in c:\program files\apache group\apache\htdocs\server\server.php on line 11
i went to php.ini and i changhe the
;extension=php_sockets.dll
to
extension=php_sockets.dll
but i havent resutls
anybody knoes why?
i use php 4.2.3
help me pls!