RE: I'm almost there! Just a little more help

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> Below is all of my code.  The first is my html page that calls my
> php page.
> I do not know php well enough to edit the code to make this work.  I need
> the image to go to a folder called "logos" on my C drive.  The actual path
> is:
> C:\Program Files\Apache Group\Apache2\htdocs\logos
>
> Could someone please make the changes to my code so that it will work!
> Thank you Thank you!!!
>
> ********HTML Page***********
> <html>
>
> <form action="fileupload2.php" method=post enctype="multipart/form-data">
> submit this file: <input type=file name="userfile"><br>
> rename to: <input type=text name="newname"><br>
> <input type=submit><br>
> </form>
> </html>
>
> **********PHP Page *************

How about... this

<?
if (is_uploaded_file($_FILES['userfile']['tmp_name'])) {

move_uploaded_file($_FILES['userfile']['tmp_name'],$_SERVER['DOCUMENT_ROOT']
.'/logos');
}
?>


-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [PHP Users]     [Postgresql Discussion]     [Kernel Newbies]     [Postgresql]     [Yosemite News]

  Powered by Linux