Cor*_*yRS 0 php file-permissions directory-permissions
检查此代码:
<?php
$url = 'http://www.example.com/downloads/count.txt';
$hit_count = @file_get_contents($url);
$hit_count++;
@file_put_contents($url, $hit_count);
header('Location: wmwc.zip');
?>
@file_get_contents工作正常,标题位置更改为下载的文件也可以,但是hit_count增加或@file_put_contents不起作用,因为文件的数量不会增加1.我已将文件权限设置为777,但是当我尝试将目录权限设置为777我也得到500内部服务器错误说"服务器遇到意外情况,导致无法完成请求".