splitbrain / dokuwiki-plugin-dw2pdf

A fork of Luigi Micco's PDF export plugin for DokuWiki
http://www.dokuwiki.org/plugin:dw2pdf
55 stars 68 forks source link

Plugin DW2PDF doesn't support custom pagesize #511

Open Juergen-aus-Zuendorf opened 2 months ago

Juergen-aus-Zuendorf commented 2 months ago

In the past, it was possible to set the parameter "pagesize" to custom values. Example: "do=export_pdf&pagesize={216,303}"

But now, when processing the plugin, there comes an error message that the pagesize isn't allowed.

Best regards Juergen

Klap-in commented 1 week ago

The format variable supports an array with the size in mm. https://mpdf.github.io/reference/mpdf-functions/construct.html However, the pagesize url parameter assumes its value is a string. So probably your array is offered as string to mpdf library and not as array with numbers. Pull request, with proper sanitizing, is welcome.