php disk_free_space 函数与disk_total_space 函数教程,第一个函数是指函数返回的空间,以字节为单位,在指定的目录,而disk_total_space 函数返回的总空间
定义和用法
该disk_free_space ( )函数返回的自由空间,以字节为单位,在指定的目录。
语法:
<span style="color: #008080">disk_free_space</span>(directory)
我们来看看disk_free_space实例吧。
<span style="color: #000000">php
</span><span style="color: #008000">//</span><span style="color: #008000"> by http://www.manongjc.com/article/1324.html </span>
<span style="color: #0000ff">echo</span> <span style="color: #008080">disk_free_space</span>("C:"<span style="color: #000000">);
</span>?>
输出你硬盘大小。
12312312313
下面再来看看disk_total_space函数的教程。
定义和用法
该disk_total_space ( )函数返回的总空间,以字节为单位,在指定的目录。
语法
<span style="color: #008080">disk_total_space</span>(directory)
实例:
<span style="color: #000000">php
</span><span style="color: #008000">//</span><span style="color: #008000"> by http://www.manongjc.com/article/1324.html </span>
<span style="color: #0000ff">echo</span> <span style="color: #008080">disk_total_space</span>("C:"<span style="color: #000000">);
</span>?>
方法与disk_free_space是一样的吧。
php免费学习视频:立即使用
踏上前端学习之旅,开启通往精通之路!从前端基础到项目实战,循序渐进,一步一个脚印,迈向巅峰!










