• Resolved alidaonline

    (@alidaonline)


    Hi there

    I’ve installed this plugin and it works great although I would like to have a situation where a user clicks on the link to print to PDF and when the new tab opens the print dialog is automatically opened.

    I know you can’t close the tab once the print dialog is closed but I would like to hide the toolbar so that users can’t save the PDF.

    Could you point me in the right direction?

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author fkrauthan

    (@fkrauthan)

    There is no option. And there is always a way to save the pdf file. So if you would only a print of your pdf you should use another plugin. wp-print for exmaple.

    Thread Starter alidaonline

    (@alidaonline)

    I found a way to remove the toolbar by adding the following code to the config.php file in the mpdf folder:

    $this->SetDisplayPreferences('/HideMenubar/HideToolbar/DisplayDocTitle');

    I know that the user can still click on File – Save As but the intention is just to discourage the average user from saving the file.

    I’ve found some code here https://www.fpdf.org/en/script/script36.php that just needed a modification to refer to the mpdf class which automatically opens the print dialog.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘[Plugin: wp-mpdf] Hide Toolbars and Force Print Dialog’ is closed to new replies.