Search code examples
javascriptphpsocketswebsocketphpwebsocket

Can't get Web Socket to work on my no-ip domain name


I am trying to build an online chatting site with Web Socket. Whenever I changed the private IP address to my no-ip domain name, an error occurred. Why?

This works (Client JavaScript):

var wsUri = "ws://192.168.1.5:9000/chat/server.php";    

This doesn't work (Client JavaScript):

var wsUri = "ws://moonvalley.no-ip.biz:9000/chat/server.php";   

Any idea?


Solution

  • I just realized that I need to perform port forwarding for my router too. I hope this will help others.