Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $string = 'привет, мир!';
- function check_encoding($string) {
- $encodings = mb_list_encodings();
- foreach ($encodings as $encoding) {
- $str[$encoding] = iconv("UTF-8", $encoding, $string);
- }
- return $str;
- }
- echo '<pre>';
- print_r(check_encoding($string));
- echo '</pre>';
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement