PHP头条
热点:

PHP网站备份程序代码分享


效果图:

PHP代码
代码如下:



网站程序备份



error_reporting(E_ALL & ~E_NOTICE);
ini_set('memory_limit', '2048M');
echo "选择要压缩的文件或目录:
";
$fdir = opendir('./');
while($file=readdir($fdir))
{
if($file=='.'|| $file=='..')
continue;
echo " ";
if(is_file($file))
{
echo "2 $file
";
}
else
{
echo "0 $file
";
}
}
?>


包含下列文件类型:


(文件类型用"|"隔开,默认空则包含任意文件,例:如果需要打包php和jpg文件,则输入"php|jpg")



压缩文件保存到目录:


(留空为本目录,必须有写入权限)



压缩文件名称:


(.zip)








相关文章

PHP之友评论

今天推荐