It sounds like you might benefit from going through the getting
started guide.  Particularly the section on templates:
http://code.google.com/intl/nl-NL/appengine/docs/python/gettingstarted/templates.html

In your template you need to print one or more of the entity's
_properties_, not the entity itself:   entity.property


Robert





On Sat, Oct 30, 2010 at 23:31, Zeynel <[email protected]> wrote:
> I fetch a list like this
>
> mylist = rep.all().fetch(1)
>
> but I cannot display it; the template renders it as an object. I use
> Mako templates. Someone at stackoverflow suggested a solution with
> Django templates like this:
>
> http://stackoverflow.com/questions/4061673/printing-lists-with-mako-template-django-join-tag
>
> But I would like to understand the right method to print a list
> object. More information below. Thanks for your help.
>
> class Rep(db.Model):
>    author = db.UserProperty()
>    replist = db.ListProperty(str)
>    unique = db.ListProperty(str)
>    date = db.DateTimeProperty(auto_now_add=True)
>
>  L = []
>        rep = Rep()
>        s = self.request.get('sentence')
>        L.append(s)
>
>        rep.replist = L
>        rep.put()
>
> mylist = rep.all().fetch(1)
>
> I get an object like this: [<__main__.Rep object at 0x04593C30>]
>
> --
> 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.
>
>

-- 
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.

Reply via email to