Would it be possible to store the uploaded file into the record that the form adds to the MySQL database? In fact, when I set up my database I created the file field as a MEDIUMBLOB object assuming that the form would automatically store the uploaded file in the database field if the field was filled in during form generation.
What sort of modification would I have to make to be able to store the uploaded file into the MySQL database record? Is it something in a form that could just be put right in or would additional processing be necessary? I'm far from expert on PHP (expert with C++, moderately skilled Python, SQL, and HTML, PHP uber-noob), but I could probably figure out what to do if pointed in the right direction.
Has anyone attempted to do this before?
I'd also like to be able to attach the file to the email that is sent. Has anyone done this successfully? It's trivial enough in Python, but I have no idea whether creating a multipart email would be a challenge in PHP.
In my most ideal situation, the script would put the uploaded file into the database, attach it to the email, and not actually store it on the server.
Thank you,
Jason Champion
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
unfortunately it is not simple enough to be handled with a small modification. but I have been thinking about uploaded file management, and maybe in the next version of phpFormGenerator I'll just have them stored in mysql rather than on disk. Although, sending email with the file as an attachment is probably not something that I would want to incorporate because it opens up lots of spamming possibilities.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I see how an email attachment could be a problem, especially where viruses and spam are concerned. However, storing files in MySQL would be most excellent because I would be able to do a lot with them and they would not be publicly available unless I wanted them to be.
I'm using a generated form for writers to submit stories in .RTF, .DOC, and .TXT format to be considered for a magazine of science fiction and fantasy stories (All Possible Worlds: http://www.allpossibleworlds.net\), so having the documents readily accessible to anyone on the 'net could be a problem.
I've made a small donation to this project in the hope that you'll be more likely to include database storage in the next release. :)
Thank you,
Jason Champion
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Would it be possible to store the uploaded file into the record that the form adds to the MySQL database? In fact, when I set up my database I created the file field as a MEDIUMBLOB object assuming that the form would automatically store the uploaded file in the database field if the field was filled in during form generation.
What sort of modification would I have to make to be able to store the uploaded file into the MySQL database record? Is it something in a form that could just be put right in or would additional processing be necessary? I'm far from expert on PHP (expert with C++, moderately skilled Python, SQL, and HTML, PHP uber-noob), but I could probably figure out what to do if pointed in the right direction.
Has anyone attempted to do this before?
I'd also like to be able to attach the file to the email that is sent. Has anyone done this successfully? It's trivial enough in Python, but I have no idea whether creating a multipart email would be a challenge in PHP.
In my most ideal situation, the script would put the uploaded file into the database, attach it to the email, and not actually store it on the server.
Thank you,
Jason Champion
unfortunately it is not simple enough to be handled with a small modification. but I have been thinking about uploaded file management, and maybe in the next version of phpFormGenerator I'll just have them stored in mysql rather than on disk. Although, sending email with the file as an attachment is probably not something that I would want to incorporate because it opens up lots of spamming possibilities.
I see how an email attachment could be a problem, especially where viruses and spam are concerned. However, storing files in MySQL would be most excellent because I would be able to do a lot with them and they would not be publicly available unless I wanted them to be.
I'm using a generated form for writers to submit stories in .RTF, .DOC, and .TXT format to be considered for a magazine of science fiction and fantasy stories (All Possible Worlds: http://www.allpossibleworlds.net\), so having the documents readily accessible to anyone on the 'net could be a problem.
I've made a small donation to this project in the hope that you'll be more likely to include database storage in the next release. :)
Thank you,
Jason Champion