I have attached an example. We have a form, where some questions are answered by selecting one or more checkboxes. Those values are being stored in the database as arrays. E2PDF appears to be just printing what is in the database instead of the reader-friendly values. How can we configure it to use the reader-friendly values?
Unfortunately E2Pdf has not yet native support of Toolset, however it must be possible to solve such task of 1 by the following ways:
E2Pdf currently can navigate via arrays by using "path" attribute on shortcode. To accomplish it with this way you must create "textarea" inside PDF with shortcode that outputs serialized value, as example we will be using: [meta key="wpcf-checkbox-1"]
In our case serialized value looks like:
a:2:{s:64:"wpcf-fields-checkboxes-option-ed2aa5d6f07e8805136cc5f32f3e77ba-1";a:1:{i:0;s:1:"1";}s:64:"wpcf-fields-checkboxes-option-d41ae1e90e0cdc01acdbc9eb2eb9ab87-1";a:1:{i:0;s:1:"1";}}
So after unserialize operation we get the path to navigate, (dot (.) must be used as delimiter between array keys), it's if you need to output values separately:
However if you need to output all values in one line, you will need to use custom function filter, which must be added to functions.php to get the list of checkboxes values and "implode" them.
Our monthly newsletter keeps you in the loop, so you'll always be up to date with the latest news and updates about E2Pdf.
All trademarks, service marks, trade names, product names, and logos appearing on this website are the property of their respective owners. The use of trademarks such as Formidable Forms®, Forminator Forms®, Gravity Forms®, JetFormBuilder®, WordPress®, WooCommerce®, WPForms® and others is solely for identification purposes (nominative use) and does not imply any affiliation, sponsorship, or endorsement by the respective trademark holders.
We use cookies to collect and analyse information on site performance and usage, to provide social media features and to enhance and customise content and advertisements.
By clicking "Accept Selected", you consent to use of selected cookies according to our
Cookie Policy.