monster.ui.renderPDF()#

Syntax#

monster.ui.renderPDF(file, target[, args]);

// Example
template.find('#upload').fileUpload({
    inputOnly: true,
    wrapperClass: 'file-upload input-append',
    btnClass: 'monster-button',
    success: function(results) {
        monster.ui.renderPDF(results[0].file, template.find('.pdf-container'));
    }
});

Parameters#

file: File (mandatory)#

File received by a fileUpload plugin.

target: jQuery object (mandatory)#

Target in which the iframe containing the PDF will be added

Description#

This helper will take a file and show it in a container, in a PDF viewer

Edit this page here