php修改指定文件的指定内容
时间:2014-08-13 03:33:05
收藏:0
阅读:330
1 <?php 2 $origin_str = file_get_contents(‘路径/文件.txt‘); 3 $update_str = str_replace(‘qwe=0‘, ‘qwe=1‘, $orgin_str); 4 file_put_contents(‘路径/文件.txt‘, $update_str); 5 ?>
原文:http://www.cnblogs.com/mrcln/p/3909064.html
评论(0)