Here is what I’m trying to do:
I have a normal form with some fields and at the bottom there is a field with a browse button. I can press the browse button and select a file (from my computer) after filling in all the textfields and then click send. Then the picture will be uploaded to a folder at my FTP server and the name of the file or the full location of the file will be saved to a MySQL database together with the information in the other fields.
I know how to save text from textfields but I just wanted to give you guys the full picture of what I’m trying to do.
I have done something similar. I created a standard file uploader that uploaded to (in my case) /var/www/uploads/. All I then had to do was find out my filename and the path I stored in the db would be ‘/var/www/uploads/filename.ext’, replacing filename.ext with what was provided by the $_FILES array.