Skip to content

Miscellaneous

pagination()

pagination() — returns any

Returns a struct with information about the specificed paginated query. The keys that will be included in the struct are currentPage, totalPages and totalRecords.

NameTypeRequiredDefaultDescription
handlestringyesqueryThe handle given to the query to return pagination information for.
allAuthors = model("author").findAll(page=1, perPage=25, order="lastName", handle="authorsData");
paginationData = pagination("authorsData");

#pagination().currentPage#
#pagination().totalPages#
#pagination().totalRecords#