|
...
|
...
|
@@ -14,8 +14,8 @@ use SwooleTW\Http\Websocket\Facades\Websocket; |
|
|
|
*/
|
|
|
|
|
|
|
|
Websocket::on('connect', function ($websocket, Request $request) {
|
|
|
|
$websocket->send("Hello, Client! You sent: 111");
|
|
|
|
@file_put_contents(storage_path('logs/lyh_error.log'), var_export(1111111, true) . PHP_EOL, FILE_APPEND);
|
|
|
|
$rs = $websocket->send("Hello, Client! You sent: 111");
|
|
|
|
@file_put_contents(storage_path('logs/lyh_error.log'), var_export($rs, true) . PHP_EOL, FILE_APPEND);
|
|
|
|
// called while socket on connect
|
|
|
|
});
|
|
|
|
|
...
|
...
|
|