How do I add a home icon to the navigation panel, that goes to a table of content page inside the PDF?
Well I figured it out, but it ain't working when using it with the PDF in a lightbox.
I'm using this code inside the "Ready function" field in the general settings:
var myFrame = $(".book-widget iframe").contents().find('body'); myFrame.find('.widToolbar .buttons').prepend('Indholdsfortegnelse'); myFrame.find('.widToolbar .indholdsfortegnelse').css('width', '30');
$(".book-widget iframe").contents().on("click", ".indholdsfortegnelse", function(e){ e.preventDefault(); scene.ctrl.goToPage(2); });
DOH, solved it. The class was no longer book-widget, since the lightbox container was another class...
Well I figured it out, but it ain't working when using it with the PDF in a lightbox.
I'm using this code inside the "Ready function" field in the general settings:
var myFrame = $(".book-widget iframe").contents().find('body'); myFrame.find('.widToolbar .buttons').prepend('Indholdsfortegnelse'); myFrame.find('.widToolbar .indholdsfortegnelse').css('width', '30');
$(".book-widget iframe").contents().on("click", ".indholdsfortegnelse", function(e){ e.preventDefault(); scene.ctrl.goToPage(2); });
DOH, solved it. The class was no longer book-widget, since the lightbox container was another class...