Filters to be used within the convert filter are base64-encode, base64-decode, quoted-printable-encode and quoted-printable-decode. Note: those are not in the string filter, as currently reported by the manual!
Example usage is:
<?php
$h = fopen('gecodeerd.txt', 'r');
stream_filter_append($h, 'convert.base64-decode');
fpassthru($h);
fclose($h);
?>
Or
<?php
$filter = 'convert.base64-decode';
$file = 'coded.txt';
$h = fopen('php://filter/read=' . $filter . '/resource=' . $file,'r');
fpassthru($h);
fclose($h);
?>
stream_get_filters
(PHP 5)
stream_get_filters — Recuperar la lista de filtros registrados
Descripción
array stream_get_filters
( void
)
Devuelve una matriz indexada que contiene el nombre de todos los filtros de secuencia disponibles en el sistema actual.
Example #1 Uso de stream_get_filters()
<?php
$lista_de_secuencias = stream_get_filters();
print_r($lista_de_secuencias);
?>
La salida será similar a la siguiente. Nota: pueden haber más o menos filtros en su versión de PHP.
Array ( [0] => string.rot13 [1] => string.toupper [2] => string.tolower [3] => string.base64 [4] => string.quoted-printable )
Vea también stream_filter_register(), y stream_get_wrappers().
stream_get_filters
Jasper Bekkers
05-Oct-2005 11:53
05-Oct-2005 11:53
