fg_entryautomation_pdf_mpdf_config
Description
This filter allows you to modify the configuration used for mPDF before it generates a PDF when a task is using PDF as its file type.
Usage
PHP
add_filter( 'fg_entryautomation_pdf_mpdf_config', 'your_function_name', 10, 3 );
Parameters
- $config array
mPDF configuration. - $task Task
The current automation Task object. - $form array
The current automation Task’s Form.
Examples
Change PDF orientation to landscape
This example will generate the PDF in landscape orientation rather than the default portrait orientation.
PHP
add_filter( 'fg_entryautomation_pdf_mpdf_config', function( $config, $task, $form ) {
$config['orientation'] = 'L';
return $config;
}, 10, 3 );
Since
This filter was added in Entry Automation 3.3