sorry for sending the last link! it was a mistake 2010/7/16 Elio Scordo <[email protected]>
> http://fireworksay.appspot.com/ > > 2010/7/16 Elio Scordo <[email protected]> > > Well, I tried without enctype="multipart/form-data" >> >> >> and self.request.POST["foo"] works ok >> >> pasting the attribute in the form: >> >> enctype="multipart/form-data" >> >> I have an exception: >> >> foo = self.request.POST["foo"] >> File "C:\Program Files >> (x86)\Google\google_appengine\lib\webob\webob\multidict.py", line 302, in >> __getitem__ >> return self._decode_value(self.multi.__getitem__(key)) >> File "C:\Program Files >> (x86)\Google\google_appengine\lib\webob\webob\multidict.py", line 77, in >> __getitem__ >> raise KeyError(key) >> KeyError: 'foo' >> >> >> I am sure that it is similar to this issue >> >> http://code.google.com/p/google-app-engine-django/issues/detail?id=13 >> >> >> But I am not able to apply the patch or identify the problem... >> >> please help!!!!! >> >> >> >> >> 2010/7/15 Ikai L (Google) <[email protected]> >> > >> > I haven't tried this code, but why not self.request.POST["file"]? >> > http://pythonpaste.org/webob/reference.html#query-post-variables >> > >> > On Thu, Jul 15, 2010 at 2:18 AM, Elio Scordo <[email protected]> >> wrote: >> >> >> >> Hi Ikai, thank you for the help. The GET method is not the point, I use >> POST. >> >> >> >> This simple form, for example: >> >> >> >> <form enctype="multipart/form-data" name="photo_form" >> >> action="/user/photo" method="post" > >> >> <input type="file" name="file" /> >> >> <input type="text" name="foo" /> >> >> >> >> </form> >> >> >> >> thefile = self.request.get("file") >> >> foo = self.request.get("foo") >> >> if thefile: >> >> >> >> It can upload pictures the first time and the stop working later. On >> >> the cloud works perfectly. >> >> >> >> In debug mode I can see self.request.get( "file") or self.request.get( >> >> "foo") returning void after the first time. >> >> >> >> I found a issue opened in 2008 and closed.. It was related to form >> parsing. >> >> >> >> Does anyone use file upload and window development environment? >> >> >> >> >> >> Thanks >> >> >> >> >> >> >> >> >> >> >> >> 2010/7/15 Ikai L (Google) <[email protected]>: >> >> > I'm pretty sure you can't use a multipart form with a GET (what is >> the >> >> > point?). Multipart only makes sense if you are passing large amounts >> of data >> >> > in the body, whereas GET requests pass parameters in the URL, often >> capped >> >> > at between 1000-2000 characters (depending on browser). Change this >> to a >> >> > POST and see what happens. >> >> > >> >> > On Fri, Jul 9, 2010 at 10:05 AM, elio <[email protected]> wrote: >> >> >> >> >> >> Hi, >> >> >> >> >> >> every call to self.request.get( ) return void after that I put the >> >> >> encoding form as enctype="multipart/form-data". >> >> >> >> >> >> The fisrt time all work good. >> >> >> >> >> >> I can not find any workaround. >> >> >> >> >> >> This problem appears only in development (windows 7 with the last >> >> >> appengine release) >> >> >> >> >> >> Any help would be really appreciated >> >> >> >> >> >> -- >> >> >> You received this message because you are subscribed to the Google >> Groups >> >> >> "Google App Engine" group. >> >> >> To post to this group, send email to >> [email protected]. >> >> >> To unsubscribe from this group, send email to >> >> >> [email protected]<google-appengine%[email protected]> >> . >> >> >> For more options, visit this group at >> >> >> http://groups.google.com/group/google-appengine?hl=en. >> >> >> >> >> > >> >> > >> >> > >> >> > -- >> >> > Ikai Lan >> >> > Developer Programs Engineer, Google App Engine >> >> > Blog: http://googleappengine.blogspot.com >> >> > Twitter: http://twitter.com/app_engine >> >> > Reddit: http://www.reddit.com/r/appengine >> >> > >> >> > -- >> >> > You received this message because you are subscribed to the Google >> Groups >> >> > "Google App Engine" group. >> >> > To post to this group, send email to >> [email protected]. >> >> > To unsubscribe from this group, send email to >> >> > [email protected]<google-appengine%[email protected]> >> . >> >> > For more options, visit this group at >> >> > http://groups.google.com/group/google-appengine?hl=en. >> >> > >> >> >> >> -- >> >> You received this message because you are subscribed to the Google >> Groups "Google App Engine" group. >> >> To post to this group, send email to [email protected] >> . >> >> To unsubscribe from this group, send email to >> [email protected]<google-appengine%[email protected]> >> . >> >> For more options, visit this group at >> http://groups.google.com/group/google-appengine?hl=en. >> >> >> > >> > >> > >> > -- >> > Ikai Lan >> > Developer Programs Engineer, Google App Engine >> > Blog: http://googleappengine.blogspot.com >> > Twitter: http://twitter.com/app_engine >> > Reddit: http://www.reddit.com/r/appengine >> > >> > -- >> > You received this message because you are subscribed to the Google >> Groups "Google App Engine" group. >> > To post to this group, send email to [email protected]. >> > To unsubscribe from this group, send email to >> [email protected]<google-appengine%[email protected]> >> . >> > For more options, visit this group at >> http://groups.google.com/group/google-appengine?hl=en. >> >> > -- You received this message because you are subscribed to the Google Groups "Google App Engine" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en.
