cURL / Mailing Lists / curl-and-php / Single Mail

curl-and-php

Re: remote file upload to remote ftp server

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Sun, 13 Nov 2005 10:39:38 +0100 (CET)

On Sun, 13 Nov 2005, dynamite media wrote:

> i need help i want to upload a "remote" file to my ftp server.

Uh, you mean that you want to *download* a file to your server? Or what
machines are actually involved here? Does your PHP program run on the same
host as the ftp server is running?

> i have read posts etc and have no idea on how to do this...
>
> this in paticular:
>
> Basics:
>
> Use a FTP URL with the target to-become file name.
>
> Pick UPLOAD
>
> Provide INFILE and INFILESIZE.
>
> Perform.
>
> Done.
> .........
>
> and have no clue what that means!

Ok, I wrote up a first and very simple example of how to do FTP upload and
published it here:

    http://curl.haxx.se/libcurl/php/examples/ftpupload.html

I'm interested in feedback and improvemtns.

> where does that even go?

This examples uploads a file from your PHP/CURL running machine to the
'mysite.com' ftp server.

> seems there is example but not for what i want,i dont want to get from my pc
> but from any file on the net

The melbourne.ug.php.net example you referred to does HTTP multipart formpost
and _not_ an FTP upload.

-- 
  Commercial curl and libcurl Technical Support: http://haxx.se/curl.html
_______________________________________________
http://cool.haxx.se/cgi-bin/mailman/listinfo/curl-and-php
Received on 2005-11-13