connect($host,$appName,$port,$data); if(isset($_SESSION["roomId"])){ $client->leaveRoom($_SESSION["roomId"]); } //$client->close(); ?>