simple upload and save jpeg

Do you have a question? Post it now! No Registration Necessary.  Now with pictures!

Threaded View
OK, this is my first time trying to let folks upload a picture and save
it.  I use a very basic html file input from

<form action="picact.php" method="post" enctype="multipart/form-data">
 <input name="picture_name" type="file" id="picture_name">
<input type="submit" name="Submit" value="Submit">

In picact.php I try to run a simply copy function

if(!(copy($picture_name, "images/picupload.jpeg"))){
    echo "trouble"; }
else {
    echo "worked";}

it tells me it worked, but there is no file in the images folder, so I
don't know what is going wrong.  does anyone have any advice?

I am using a static file name for now, to avoid any trouble with
variable names.


Re: simple upload and save jpeg wrote:
Quoted text here. Click to load it

You are totally on the wrong track.

Please read:

On that page you will find a example how it should be done.

Franck Nijhof
BlueSolid Software

Site Timeline