Home > php教程 > php手册 > body text

php压缩解压文件

WBOY
Release: 2016-06-13 10:43:35
Original
977 people have browsed it

 

php上传rar压缩包并解压到目录

1.php上传并解压的原理

普通上传功能  上传服务器

rar

zip    加载系统组件  执行解压命令  成功解压到目录

7z

2.php执行系统命令的几类函数的区别

system()输出并返回最后一行shell结果

exec()不输出结果,返回最后一行shell结果

passthru()只调用命令,把运行结果原样输出

new com()系统预定义com类,根据需要任意选择内置方法

3.使用php预定义com组件加载shell

$obj=new com('wscript.shell');加载wscript.shell来执行dos命令的组件

$obj->run('所要执行的命令内容');

rar解压命令:winrar x 被解压文件  解压位置

4.实例操作php上传解压案例

获取当前绝对路径getcwd();

上传移动文件函数  move_uploaded_file();

本文出自 “r0otkit” 博客

source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Recommendations
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!