mirror of
https://codeberg.org/icewind/SMB.git
synced 2026-06-03 17:24:07 +02:00
update readme
This commit is contained in:
parent
c1afd721f2
commit
fa4918ac41
1 changed files with 16 additions and 0 deletions
16
README.md
16
README.md
|
|
@ -134,3 +134,19 @@ if (Server::NativeAvailable()) {
|
||||||
$share = $server->getShare('test');
|
$share = $server->getShare('test');
|
||||||
$share->put($fileToUpload, 'example.txt');
|
$share->put($fileToUpload, 'example.txt');
|
||||||
```
|
```
|
||||||
|
|
||||||
|
### Using notify
|
||||||
|
|
||||||
|
```php
|
||||||
|
<?php
|
||||||
|
use Icewind\SMB\Server;
|
||||||
|
|
||||||
|
require('vendor/autoload.php');
|
||||||
|
|
||||||
|
$server = new Server('localhost', 'test', 'test');
|
||||||
|
$share = $server->getShare('test');
|
||||||
|
|
||||||
|
$share->notify('')->listen(function (\Icewind\SMB\Change $change) {
|
||||||
|
echo $change->getCode() . ': ' . $change->getPath() . "\n";
|
||||||
|
});
|
||||||
|
```
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue