dismiss Step into the future! Click here to switch to the beta php.net site
downloads | documentation | faq | getting help | mailing lists | licenses | wiki | reporting bugs | php.net sites | conferences | my php.net

search for in the

stream_filter_append> <stream_copy_to_stream
[edit] Last updated: Fri, 28 Jun 2013

view this page in

stream_encoding

(No version information available, might only be in SVN)

stream_encodingSet character set for stream encoding

Description

bool stream_encoding ( resource $stream [, string $encoding ] )
Warning

This function is currently not documented; only its argument list is available.



add a note add a note User Contributed Notes stream_encoding - [1 notes]
up
1
hajo at clansphere dot de
4 years ago
with php 5.2+ you can (should!) use the following line next to e.g. fopen() and specify the encoding of the content:

<?php
$charset
= 'UTF-8';

stream_encoding($handle, $charset);
?>

in addition php 6 seems to need this since it triggers a notice level error if special chars must be converted and the above command is not specified (binary data excluded - just talkin bout clear text in this comment)

 
show source | credits | stats | sitemap | contact | advertising | mirror sites