生成的代码 data/ss.php

<?php
return  
array (
  'name' => '1111',
  'title' => '2222',
);

 

php代码

$str = "<?php\nreturn  \n";
        $myfile = fopen("data/ss.php", "w") or die("Unable to open file!");

        fwrite($myfile, $str);

        fwrite($myfile, var_export($data, true));
        fwrite($myfile, ';');
        fclose($myfile);

 

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2021-12-09
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2022-01-02
  • 2022-02-13
  • 2022-12-23
  • 2022-12-23
  • 2021-11-25
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案