Hi.

I'm not familiar with Dajax, but I think your response could include
the required HTML markup and you would just append it to the list of
items.
Doing so you will always use the same template snippet you've used for
the initial set of items (makes it easier to maintain, since you don't
need to change the JS if you change your markup).

Mathias

On Nov 4, 10:56 am, Daniel França <[email protected]> wrote:
> Hi,
> I'm trying to create a twitter-like effect on my page to show more items
> when necessary ("More items" button)
> Like when in the twitter you click to see more tweets (the old twitter page)
>
> I'm trying to create this effect using Dajax, the best solution I thought
> was that:
> I do load the page with the initial set of items, and I've a hide <div> with
> a "template" of the item structure, when the user clicks on "More items" the
> Dajax functions gets the div innerHTML and use it as a template to generate
> the others divs with the real items... so I return this to the page that
> shows the new items.
> But it still sounds like a workaround, don't, I think there's a more elegant
> way to do that.
>
> Any suggestion?
>
> Best Regards,
> Daniel França

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" 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/django-users?hl=en.

Reply via email to