php 下载文件
function dlfile($file_url, $save_to)
{
$content = file_get_contents($file_url);
file_put_contents($save_to, $content);
}
pathinfo
返回 extension filename basename
pathinfo("/testweb/test.txt")
Array
(
[dirname] => /testweb
[basename] => test.txt
[extension] => txt
)
网友评论