wget --post-file=1.jpg --header="Content-Type: image/jpg"
"http://myserver/upload_file.php";

... --header="...

Paul


On Fri, Oct 19, 2012 at 12:43 PM, kris Occhipinti <[email protected]> wrote:
> Hello,
>
> I'm on Debian SID,
> working with wget Version: 1.14-1.
> I've created a php file on my webserver for uploading images.
> I used the code from this page 
> http://www.w3schools.com/php/php_file_upload.asp
>
> Uploading to the site works find in the webbrowser using html form,
> but I get an "Invalid file" when I try and use wget like this:
> wget --post-file=1.jpg --header "Content-Type: image/jpg"
> "http://myserver/upload_file.php";
>
> I know I've uploaded files with wget before, but can't tell what I'm
> doing wrong now.
> I'm trying to upload the same file that I uploaded through the web browser
> so, I don't think it's the file or the php code.
>
> Any help would be great.
>
> --
> Kris Occhipinti
> Don't give Microsoft the remote control. Don't use Windows 7.
> <http://windows7sins.org>
>

Reply via email to