To pass decrypted field data to gravity PDF you can use a custom template to place decrypted merge tags as desired. A basic starter template is available for download below.
Instructions:
Using this starter template you can create a custom PDF file with decrypted field data using HTML with MERGE TAGS and/or PHP (site, form, entry, and field data). By default it simply prints all field data using the {gfef_decrypt_ALL+} merge tag (any decrypted merge tags used must be unlocked for use on the Gravity Forms Encrypted Fields settings page. Please do this first if you intend to use this template). You can use any available standard Gravity Forms or Decrypted merge tags and they will function here that same as in a notification or confirmation.
Download and unzip the file.
Open the file in a code or text editor and edit the basic text and layout html if desired.
Place the PHP template file in your /wp-content/uploads/PDF_EXTENDED_TEMPLATES/ folder to add it to your available PDF templates
Place the PNG image file in your /wp-content/uploads/PDF_EXTENDED_TEMPLATES/images folder to add it to your available PDF template images. You can swap this image out later if you customize the template further. When a user selects a PDF template to use from the admin area they’ll see a preview of that template if it exists. To add preview image support for any new custom PDF template just save a 768×576 PNG to the images folder in the matching PDF template working directory (generally: /wp-content/uploads/PDF_EXTENDED_TEMPLATES/images) and name it the same as your template except for the file extension (.png).
FULL DOCUMENTATION: https://gravitypdf.com/documentation/v4/developer-start-customising/
The following PHP variables are available to all v4+ PDF templates:
$form #form
The current Gravity Form object being processed. This is the main object in Gravity Forms and contains all properties of a particular form – form title, fields, notification, confirmation ect.
$entry #entry
The current Gravity Form entry object being processed. This object contains all properties of a particular entry in raw format – accessing field data directly from the object should be avoided. The object is formatted as an associative array and the field IDs are the array keys.
$lead #lead
An alias for $entry
$form_data #form_data
The formatted $entry data stored in an associative array. View full documentation on the $form_data array.
$settings #settings
The current PDF configuration settings in array format. Standard settings like filename and font size are stored in this array, as well as template-specific settings.
$fields #fields
An array of the current Gravity Forms fields which can be accessed using their field ID number – print_r( $fields[20] );. This is just a formatted version of the $form[‘fields’] array.
$gfpdf #gfpdf
This is the main Gravity PDF object which contains all our helper classes (including data, form, options, notices, misc and log). Power users may find this useful.
$args #args
An associative array containing all of the above variables. For instance $args[‘form’] or $args[‘entry’] reference $form and $entry, respectively.
For backwards compatibility, these variables are available to templates but are deprecated:
$form_id #form_id
The current form ID being processed. We recommend you use $form[‘id’] or $entry[‘form_id’] instead.
$lead_id #lead_id
The current entry ID being processed. We recommend you use $entry[‘id’] instead.
$lead_ids #lead_ids
An array of the selected entries to be processed. This array was used in Gravity PDF v3 to process multiple entries in a single PDF, but this had a lot of performance problems and has been removed in v4+. We strongly recommend against using this.