Last active
June 27, 2019 15:49
-
-
Save ennjoy/3b5fbc897f794a042c1dd4021129ab5b to your computer and use it in GitHub Desktop.
array php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function json_encode_cyr($array) { | |
$str = json_encode($array, JSON_UNESCAPED_UNICODE | JSON_NUMERIC_CHECK); | |
return $str; | |
} | |
$array = array( | |
'id' => 1, | |
'login' => 'test', | |
'browser' => 'google' | |
); | |
json_encode_cyr($array); | |
?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment