2002-04-15 00:12:54 +00:00
|
|
|
<?xml version="1.0" encoding="iso-8859-1"?>
|
2005-01-16 05:09:23 +00:00
|
|
|
<!-- $Revision: 1.7 $ -->
|
|
|
|
<refentry id="function.ftp-close">
|
|
|
|
<refnamediv>
|
|
|
|
<refname>ftp_close</refname>
|
|
|
|
<refpurpose>Closes an FTP connection</refpurpose>
|
|
|
|
</refnamediv>
|
|
|
|
<refsect1 role="description">
|
|
|
|
&reftitle.description;
|
|
|
|
<methodsynopsis>
|
|
|
|
<type>bool</type><methodname>ftp_close</methodname>
|
|
|
|
<methodparam><type>resource</type><parameter>ftp_stream</parameter></methodparam>
|
|
|
|
</methodsynopsis>
|
|
|
|
<para>
|
|
|
|
<function>ftp_close</function> closes the given link identifier
|
|
|
|
and releases the <type>resource</type>.
|
|
|
|
</para>
|
|
|
|
<note>
|
|
|
|
<para>
|
|
|
|
After calling this function, you can no longer use the FTP connection and
|
|
|
|
must create a new one with <function>ftp_connect</function>.
|
|
|
|
</para>
|
|
|
|
</note>
|
|
|
|
</refsect1>
|
|
|
|
<refsect1 role="parameters">
|
|
|
|
&reftitle.parameters;
|
|
|
|
<para>
|
|
|
|
<variablelist>
|
|
|
|
<varlistentry>
|
|
|
|
<term><parameter>ftp_stream</parameter></term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
|
|
|
The link identifier of the FTP connection.
|
|
|
|
</para>
|
|
|
|
</listitem>
|
|
|
|
</varlistentry>
|
|
|
|
</variablelist>
|
|
|
|
</para>
|
|
|
|
</refsect1>
|
|
|
|
<refsect1 role="returnvalues">
|
|
|
|
&reftitle.returnvalues;
|
|
|
|
<para>
|
|
|
|
&return.success;
|
|
|
|
</para>
|
|
|
|
</refsect1>
|
|
|
|
<refsect1 role="examples">
|
|
|
|
&reftitle.examples;
|
|
|
|
<para>
|
|
|
|
<example>
|
|
|
|
<title><function>ftp_close</function> example</title>
|
|
|
|
<programlisting role="php">
|
2003-12-19 14:40:54 +00:00
|
|
|
<![CDATA[
|
|
|
|
<?php
|
|
|
|
|
|
|
|
// set up basic connection
|
|
|
|
$conn_id = ftp_connect($ftp_server);
|
|
|
|
|
|
|
|
// login with username and password
|
|
|
|
$login_result = ftp_login($conn_id, $ftp_user_name, $ftp_user_pass);
|
|
|
|
|
|
|
|
// print the current directory
|
|
|
|
echo ftp_pwd($conn_id); // /
|
|
|
|
|
|
|
|
// close this connection
|
|
|
|
ftp_close($conn_id);
|
|
|
|
?>
|
|
|
|
]]>
|
2005-01-16 05:09:23 +00:00
|
|
|
</programlisting>
|
|
|
|
</example>
|
|
|
|
</para>
|
|
|
|
</refsect1>
|
|
|
|
<refsect1 role="seealso">
|
|
|
|
&reftitle.seealso;
|
|
|
|
<para>
|
|
|
|
<simplelist>
|
|
|
|
<member><function>ftp_connect</function></member>
|
|
|
|
</simplelist>
|
|
|
|
</para>
|
|
|
|
</refsect1>
|
|
|
|
</refentry>
|
2002-04-15 00:12:54 +00:00
|
|
|
|
|
|
|
<!-- Keep this comment at the end of the file
|
|
|
|
Local variables:
|
|
|
|
mode: sgml
|
|
|
|
sgml-omittag:t
|
|
|
|
sgml-shorttag:t
|
|
|
|
sgml-minimize-attributes:nil
|
|
|
|
sgml-always-quote-attributes:t
|
|
|
|
sgml-indent-step:1
|
|
|
|
sgml-indent-data:t
|
|
|
|
indent-tabs-mode:nil
|
|
|
|
sgml-parent-document:nil
|
|
|
|
sgml-default-dtd-file:"../../../../manual.ced"
|
|
|
|
sgml-exposed-tags:nil
|
|
|
|
sgml-local-catalogs:nil
|
|
|
|
sgml-local-ecat-files:nil
|
|
|
|
End:
|
|
|
|
vim600: syn=xml fen fdm=syntax fdl=2 si
|
|
|
|
vim: et tw=78 syn=sgml
|
|
|
|
vi: ts=1 sw=1
|
|
|
|
-->
|