I'm trying to use the following code:
$this->socket = fsockopen($this->server,$this->port, $errno, $errstr, $timeout = 300) or die($errstr);
It is running well in localhost but when I'm trying to run it in remote server then it is giving the following error:
Warning: fsockopen(): unable to connect to demo.demo.com:1863 in /home/demo/public_html/demo/demo/demo/demo.php on line 123
Connection timed out
I have also checked that whether the server is enabled for socket. But I found it is enabled in the server.
Can anybody help me to know what is the reason behind the connection timeout?
Thanks in advance...