PHP ftp_get_option() 函数

PHP 教程 · 2019-01-26 08:26:59

定义和用法

The ftp_get_option() 函数返回 FTP 连接的各种运行时选项。

语法


ftp_get_option(ftp_connection,option)


参数 描述
ftp_connection 必需。规定要使用的 FTP 连接。
option 必需。规定要返回的运行时选项。可能的值:
  • FTP_TIMEOUT_SEC - 返回网络操作的时间限制
  • FTP_AUTOSEEK - 如果设置该选项则返回 TRUE,否则返回 FALSE。

实例


<?php
$conn = ftp_connect("ftp.testftp.com") or die("Could not connect");
ftp_login($conn,"admin","ert456");
echo ftp_get_option($conn,FTP_TIMEOUT_SEC);
ftp_close($conn);
?>

上面的代码将输出:


90


点击查看所有 PHP 教程 文章: https://www.codercto.com/courses/l/5.html

查看所有标签

Lean Analytics

Lean Analytics

Alistair Croll、Benjamin Yoskovitz / O'Reilly Media / 2013-3-18 / USD 29.99

If you're involved with a startup, analytics help you find your way to the right product and market before the money runs out. But with a flood of information available, where do you start? This book ......一起来看看 《Lean Analytics》 这本书的介绍吧!

JS 压缩/解压工具
JS 压缩/解压工具

在线压缩/解压 JS 代码

图片转BASE64编码
图片转BASE64编码

在线图片转Base64编码工具

Markdown 在线编辑器
Markdown 在线编辑器

Markdown 在线编辑器