Skip to main content
August 26, 2007
Question

PHP insert/update record with file upload

  • August 26, 2007
  • 1 reply
  • 2371 views
I used Dreamweaver's Insert Record wizard to make a php/mysql page. In this Insert Record application I would like to have a File Field that uploads a file to an "upload" directory on the website and adds the file name to the database as text (not the entire path C:/Mydocuments etc., just the file name). How do I do that? Thank you.
This topic has been closed for replies.

1 reply

Inspiring
August 26, 2007
bcmpro wrote:
> I would like to have a File Field that uploads a file
> to an "upload" directory on the website and adds the file name to the
> database as text

Dreamweaver won't automate it for you. You either need to buy a
commercial extension (DMXZone, WebAssist, and Adobe Dreamweaver
Developer Toolbox all offer paid-for solutions), or you need to roll
your own. My book, "PHP Solutions" has detailed instructions for
uploading files in a secure manner. Alternatively, you can learn all
about PHP file uploads free of charge from the PHP manual:

http://www.php.net/manual/en/features.file-upload.php

--
David Powers, Adobe Community Expert
Author, "The Essential Guide to Dreamweaver CS3" (friends of ED)
Author, "PHP Solutions" (friends of ED)
http://foundationphp.com/