Additional Documentation for:

ssh2_scp_send()
ssh2_scp_recv()


git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@176093 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
Sara Golemon 2004-12-30 19:49:57 +00:00
parent 6e6bc33d3b
commit b9801a975a
2 changed files with 49 additions and 8 deletions

View file

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='iso-8859-1'?>
<!-- $Revision: 1.1 $ -->
<!-- $Revision: 1.2 $ -->
<!-- Generated by xml_proto.php v2.1. Found in /scripts directory of phpdoc. -->
<refentry id="function.ssh2-scp-recv">
<refnamediv>
@ -17,9 +17,29 @@
<methodparam><type>string</type><parameter>local_file</parameter></methodparam>
</methodsynopsis>
<para>
Copies a file from the remote server to the local filesystem.
</para>
<simpara>
Copy a file from the remote server to the local filesystem using the SCP protocol.
</simpara>
<example>
<title>Downloading a file via SCP</title>
<programlisting role="php">
<![CDATA[
<?php
$connection = ssh2_connect('shell.example.com', 22);
ssh2_auth_password($connection, 'username', 'password');
ssh2_scp_recv($connection, '/remote/filename', '/local/filename');
?>
]]>
</programlisting>
</example>
<simpara>
See Also:
<function>ssh2_scp_send</function>, and
<function>copy</function>
</simpara>
</refsect1>
</refentry>

View file

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='iso-8859-1'?>
<!-- $Revision: 1.1 $ -->
<!-- $Revision: 1.2 $ -->
<!-- Generated by xml_proto.php v2.1. Found in /scripts directory of phpdoc. -->
<refentry id="function.ssh2-scp-send">
<refnamediv>
@ -18,9 +18,30 @@
<methodparam choice="opt"><type>int</type><parameter>create_mode</parameter></methodparam>
</methodsynopsis>
<para>
Copy a file from the local filesystem to the remote server.
</para>
<simpara>
Copy a file from the local filesystem to the remote server using the SCP protocol.
The file will be created with the mode specified by <parameter>create_mode</parameter>.
</simpara>
<example>
<title>Uploading a file via SCP</title>
<programlisting role="php">
<![CDATA[
<?php
$connection = ssh2_connect('shell.example.com', 22);
ssh2_auth_password($connection, 'username', 'password');
ssh2_scp_send($connection, '/local/filename', '/remote/filename', 0644);
?>
]]>
</programlisting>
</example>
<simpara>
See Also:
<function>ssh2_scp_recv</function>, and
<function>copy</function>
</simpara>
</refsect1>
</refentry>