PDA

View Full Version : html upload file form--how?


crashingwaves
10-28-2005, 03:09 AM
First, let me explain that forms are my weak point when it comes to html coding--I'm not terribly good at them, but I'm getting better. Please keep that in mind as I ask stupid/obvious questions. :rolleyes:

What I want is a form that allows me to upload a file from the computer, as well as enter in information that will be entered into an SQL database. Now, entering the information into the database, I can handle. What I can't figure out is how to upload the picture. All of the examples I've looked at, both online and in my help books, use some sort of cgi-bin stuff, but nothing explains exactly what that is, how to use it, etc. So how, exactly, does one go about directing the file to upload into a particular directory within the file structure?

Thanks for any help you can give! :)

thesavior
10-28-2005, 05:56 AM
youll need to use php for this. Mysql calling needs php.

crashingwaves
10-30-2005, 04:08 PM
I know that I need to use php--that will be what I use to insert the information into the database, along with MySQL. What I don't know how to do, and what my books and things online seem to suggest I can do with html, is how to do a file upload to a specific directory. Is this not possible with html?

Glass Casket
10-30-2005, 04:52 PM
I know that I need to use php--that will be what I use to insert the information into the database, along with MySQL. What I don't know how to do, and what my books and things online seem to suggest I can do with html, is how to do a file upload to a specific directory. Is this not possible with html?

All the HTML will do for a form is define which script will take action once you click on the submit button and all the names of your field. And it is in your PHP script that you will tell which directory you want to upload your files to.