Method: addPage

From Turn.js Documentation
Revision as of 04:03, 7 July 2012 by Emmanuel (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Adds a page to the flipbook.

Parameter Type Description Default Value
element jQuery element Pointer to the DOM element of the page
$("<div />")
pageNumber Number Page Number

To insert the page 10, you can just do:

element = $("<div />").html("Loading...");
$("#flipbook").turn("addPage", element, 10);


element = $("<div />", {"class": "p10"}).html("Loading...");
$("#flipbook").turn("addPage", element);

Notice that the CSS class p10 also indicates the page number being inserted.

See also

Event: missing <yambe:breadcrumb>Turn Methods</yambe:breadcrumb>