i am trying to run the app on two different computer connected via home router with one as a server running server.php but i am facing a problem . I dont know where to put the server ip address 192.168.0.110 and where to put the clients ip address 192.168.0.116 in server.php file .I have already put my server ip address const wsChat = new WebSocket(“ws://192.168.0.110:8080/comm".
whats wrong in the code below ?
//set an array of origins allowed to connect to this server
$allowed_origins = [‘localhost’, ‘127.0.0.1’,’192.168.0.110'];
// Run the server application through the WebSocket protocol on port 8080
$app = new Ratchet\App(‘192.168.0.110’, 8080, ‘0.0.0.0’);//App(hostname, port, ‘whoCanConnectIP’, ‘’)
//create socket routes
//route(uri, classInstance, arrOfAllowedOrigins)
$app->route(‘/comm’, new Comm, $allowed_origins);