…Let's finish up our look at jQuery template by seeing…how to do things like build paged templates, as well…as some additional binding options that you can set on…the jQuery template plugin to achieve some other desired outcomes.…So you've probably seen paged results before, either in…search results or real estate listings or catalogs or whatever.…And this is, of course, the case where you display some results.…And they give the user previous and next…buttons that they can move through the data.…
And that's what we're going to do here.…So, the way that you do this in jQuery…template is on the load template function, up until…now, we've been passing the template ID or the…name of the external template file along with the data.…But there's a third argument, which are options…you can set on the load template function itself.…And so in the options object, if you set a few fields,…you can load the data in a way that it is paged.…So the first thing you do, is there's a paged field.…
You set that to true.…There's a page number field, and that's where you set…
- What is templating?
- Defining templates in jQuery Template
- Using simple Mustache templates with sections and conditions
- Adding conditionals and loops to Handlebars templates
- Working with Dust templates