Newbie: upload and MySql
Hi, I went thru mailing list but I did not find a response to my problem. I've written simple form with one text field and one file type: <form action="/content/result" method="post" ENCTYPE="multipart/form-data"> <input name="c_title" width=30 value=""> <input type="file" name="c_body:file" width=30> <input type="SUBMIT" name="SUBMIT" value="Submit"> </form> result method is: .... <dtml-call "manage_upload(REQUEST['c_body'].read())"> <dtml-var REQUEST> .... When I press Submit button I get Error Type: NameError Error Value: manage_upload Any suggestion? b) How can I simply affiche (if I find a PB) the upload content in browser? c) How can insert uploaded content in MySql. I Have to use: VALUES ( '<dtml-var c_title>', '<dtml-call "manage_upload(REQUEST['c_body'].read())">' ) It works? it seems bizarre? Thank's __________________________________________________ Do You Yahoo!? Talk to your friends online with Yahoo! Messenger. http://im.yahoo.com
b) How can I simply affiche (if I find a PB) the upload content in browser?
c) How can insert uploaded content in MySql. I Have to use:
manage_upload is used to modify the contents of a file object. It sounds like what you want is simply: <dtml-var "REQUEST['c_body'].read()"> or: VALUES ( '<dtml-var c_title>', '<dtml-var "REQUEST['c_body'].read()">' ) -jfarr
participants (2)
-
Jonothan Farr -
Marc DANAI