Home >Backend Development >PHP Tutorial >php 长整形转字符串

php 长整形转字符串

WBOY
WBOYOriginal
2016-06-23 13:09:361416browse

$str = '{"id":5730528714937479169,"fullname":"rourou","email":null,"mobile":"1391730****","description":null}';$str = preg_replace('/"id":(\d{1,}),/', '"id":"\\1",' ,  $str);echo $str;$jsondata=json_decode($str,true);echo "<pre class="brush:php;toolbar:false">";var_dump($jsondata);

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn