Jump to content

Question concerning FTP functions


cynical825

Recommended Posts

Hi,
I am looking to use some of the built-in FTP functions (http://us2.php.net/ftp) in a script I am working on and I have a quick question concerning one of the functions: [b]ftp_put[/b].

Say I am going to call ftp_put(stream, remote_file, local_file, mode) . I am confused about the remote_file and local_file arguments: Remote file would be the source, correct? And local_file is the destination? Also, does this mean remote_file can be a file on the end-users computer (ie. a file path: C:\WINDOWS\whatev.exe)?

Thanks for any help,
--Cynical
Link to comment
Share on other sites

[quote]remote_file

    The remote file path.
local_file

    The local file path. [/quote]

When you execute the command you put 'local_file' on the server as 'remote_file'.  In other words, remote_file doesn't have to exist, when the command is executed it copies local_file to the server as remote_file, even if the file names differ.
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.