Need help processing upload form with Google App Engine Blobstore?

The problem is that your posted form data is lost when you redirect the request to "/save/%s", which is normal Instead of redirecting, you should put your code inside UploadHandler, like this (untested code) : class UploadHandler(blobstore_handlers. BlobstoreUploadHandler): def post(self): try: upload_files = self. Get_uploads('file') blob_info = upload_files0 newFile = StoredFiles() newFile.

Nickname = self.request. Get('nickname') newFile. Blobkey = blob_info.key() newFile.put() self.

Redirect('/') except: self. Redirect('/upload_failure. Html') See this page from the docs for a similar example : http://code.google.com/appengine/docs/python/tools/webapp/blobstorehandlers.html#BlobstoreUploadHandler.

The problem is that your posted form data is lost when you redirect the request to "/save/%s", which is normal. Instead of redirecting, you should put your code inside UploadHandler, like this (untested code) : class UploadHandler(blobstore_handlers. BlobstoreUploadHandler): def post(self): try: upload_files = self.

Get_uploads('file') blob_info = upload_files0 newFile = StoredFiles() newFile. Nickname = self.request. Get('nickname') newFile.

Blobkey = blob_info.key() newFile.put() self. Redirect('/') except: self. Redirect('/upload_failure.

Html') See this page from the docs for a similar example : http://code.google.com/appengine/docs/python/tools/webapp/blobstorehandlers.html#BlobstoreUploadHandler.

Thank you! I thought I had tried something like this before and failed, but I'm sure there was some other error creeping in. Will try your solution later today.

– Sologoub Oct 8 '10 at 15:39 worked perfectly! Thanks! – Sologoub Oct 9 '10 at 4:38 Np, glad it worked.

:) – Franck Oct 10 '10 at 0:58.

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions