PHP » GoLang |
login |
register |
about
|
GoLang stream_filter_register
request it (448)
GoLang replacement for PHP's stream_filter_register
[edit | history]
stream_filter_register(PHP 5, PHP 7) stream_filter_register — Register a user defined stream filter Description
bool stream_filter_register
( string
$filtername
, string $classname
)stream_filter_register() allows you to implement your own filter on any registered stream used with all the other filesystem functions (such as fopen(), fread() etc.). Parameters
Return Values
Returns
stream_filter_register() will return Examples
Example #1 Filter for capitalizing characters on foo-bar.txt stream The example below implements a filter named strtoupper on the foo-bar.txt stream which will capitalize all letter characters written to/read from that stream.
<?php The above example will output: LINE1 WORD - 2 EASY AS 123
Example #2 Registering a generic filter class to match multiple filter names.
<?php The above example will output: LINE1 WORD - 2 EASY AS 123 See Also
|
more
Recently updated
more
Most requested
more
Last requests
|