Hello Ben, On Wed, Jun 26, 2013 at 12:10 PM, ben <[email protected]> wrote: > > I'm trying to create a social web application with JAVA eclipse and Google > app engine that offers its users to share and discuss photos. It should > consist of a single web page, that displays posts and the comments to each > post. Each comment belongs to exactly one post and therefore each post has > a (possibly empty) list of comments. i still have many problems with > displaying posts and saving comments with App Engine data store (HRD) !! > > Could you please give some suggestions, how can I post image and save > comment using HRD ? >
It looks like you're trying to create an imageboard-style ( http://en.wikipedia.org/wiki/Imageboard ) web application, correct? If so, you don't need to code it by yourself; there are many open source implementations you could use such as TinyBoard ( http://tinyboard.org/ ). If you really want to code this by yourself, then you can do so easily with App Engine. You can upload an image by using the Blobstore (example source code here: https://developers.google.com/appengine/docs/java/blobstore/#Uploading_a_Blob ). In regards to the comments, you'll need to retrieve the contents of the user's message using standard parameter retrieval: String post_text = req.getParameter("post_text"); Then you can store it in the datastore by creating an entity, storing the post comment as a property, then saving it to the datastore. Here's a code example: https://developers.google.com/appengine/docs/java/datastore/entities#Creating_an_Entity ----------------- -Vinny P Technology & Media Advisor Chicago, IL App Engine Code Samples: http://www.learntogoogleit.com -- You received this message because you are subscribed to the Google Groups "Google App Engine" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/google-appengine. For more options, visit https://groups.google.com/groups/opt_out.
