Hi everyone,
I am just getting started with gadgets and have a lot to learn, but so
far, it's a lot of fun.
Anyway, I hope this question makes sense.
I would like to create a gadget that can upload photos to a web album
(like Picassa Web Albums) from your computer, among other things.
I've never really worked with this kind of stuff before, but I think
the following is true:
* to submit a photo, you use the file uploader input type in an html
form
* the html form must have an encoding type of "multipart/form-data"
* normally (i.e. if you just submit the form synchronously using a
submit button or javascript) the browser will handle this somewhat
complicated encoding for you automatically
* with Google Gadgets, when you want to post data to an external URL,
you use gadgets.io.makeRequest and you make sure you set the HTTP
method to post, and the post data to the output of
gadgets.io.encodeValues(...)
* gadgets.io.encodeValues(), at least by default, supports the more
usual, simpler encoding type of "application/x-www-form-urlencoded";
it is unclear to me if it also supports the type you need for photo
(er file) upload or not ("multipart/form-data")
Given all of this, does anyone know if/how to use the
gadgets.io.makeRequest function to upload a photo in the background
(i.e. no page reload) from a google gadget? Can I just set the
encoding type properly and use encodeValues()? How about an IFrame
with Javascript?
Thanks,
T
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"iGoogle Developer Forum" 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-Gadgets-API?hl=en
-~----------~----~----~----~------~----~------~--~---