So, in my app, I will be making REST calls to the server that will send me back JSON of data. In one example a List of Users get returned froma query I run that I get friends of friends as a list. I want to display them on my page to look and act just like searching and adding friends on FaceBook. I could put it into an overlay and scrolling, but sometimes the List of Users I get, might be a list of Users attending an event, so not as large a list. I want that list of Users on the page itself in the middle content. I plan on making it very pretty and want to avoid using tables, but it might also end up needing pagination. I already have the serverside set up for pagination, I just pass the page number and number of users.
One idea I had was to have a div or section that holds the placeholders for a user, and when I get the list of Users, loop through the users and clone the div for each user and show it in the content section in a list of items.
Third idea, there are table jquery plugins, but the look and feel of those plugins is very much table look and feel. I don't want columns. All the data for me I would put in one column with css to make it look cool.
Are there any other possible ideas I don't know about. (JSP page rendering on the serverside is not a solution for me) I only have one jsp page and that is the index to get the page started.
Bear Bibeault wrote:You might want to check out the jQuery tmpl plugin, which provides client-side templating.
Thanks Bear, I had looked at it before, but had forgotten about it. But reading about it it says that it is in beta and that it will not be worked on, that there are two other sort of alternatives and I can't tell but looks like competing ones between jsRender/jsViews and JQuery UI templates. I think the latter isn't completed yet.