标签:
<?php$c = file_get_contents(‘./cities_v2.json‘);$s = "<?php return " . var_export(json_decode($c, true), true) . ";?>";file_put_contents(‘./cities_config.php‘, $s);?>
PHP 读json文件并转php配置文件
原文地址:http://www.cnblogs.com/jdhu/p/4413603.html