README
Added PHP syntax to README
This commit is contained in:
parent
1fe4b051be
commit
6a5c708775
@ -15,7 +15,8 @@ Re-use your application without changing any of its code just by wrapping it in
|
|||||||
|
|
||||||
###A Quick server example
|
###A Quick server example
|
||||||
|
|
||||||
<?php
|
```php
|
||||||
|
<?php
|
||||||
namespace Me;
|
namespace Me;
|
||||||
use Ratchet\SocketObserver, Ratchet\SocketInterface;
|
use Ratchet\SocketObserver, Ratchet\SocketInterface;
|
||||||
use Ratchet\Socket, Ratchet\Server, Ratchet\Protocol\WebSocket;
|
use Ratchet\Socket, Ratchet\Server, Ratchet\Protocol\WebSocket;
|
||||||
@ -56,3 +57,4 @@ Re-use your application without changing any of its code just by wrapping it in
|
|||||||
// Run the server application through the WebSocket protocol
|
// Run the server application through the WebSocket protocol
|
||||||
$server = new Server(new Socket, new WebSocket(new Chat));
|
$server = new Server(new Socket, new WebSocket(new Chat));
|
||||||
$server->run('0.0.0.0', 80);
|
$server->run('0.0.0.0', 80);
|
||||||
|
```
|
Loading…
Reference in New Issue
Block a user