mirror of
https://github.com/fenom-template/fenom.git
synced 2023-08-10 21:13:07 +03:00
Update usage.md
This commit is contained in:
parent
ec1dba923c
commit
a10808d1f3
@ -29,10 +29,10 @@ $result = $fenom->fetch("template/name.tpl", $vars);
|
||||
|
||||
Create pipe-line into callback
|
||||
```php
|
||||
$fenom->export(
|
||||
$fenom->pipe(
|
||||
"template/sitemap.tpl",
|
||||
$vars,
|
||||
$callback = [new SplFileObject("/tmp/sitemap.xml", "w"), "fwrite"], // pipe to file /tmp/sitemap.xml
|
||||
$chunk_size = 1e6 // chunk size for callback
|
||||
);
|
||||
```
|
||||
```
|
||||
|
Loading…
Reference in New Issue
Block a user