Global Shortcodes


[e2pdf-download]

Shortcode applied to generate and output PDF download link.

Example:

[e2pdf-download id="1"]

Can be used inside:

  • Formidable Forms
    • Success Message
    • Email Notification Message
    • Views* ([e2pdf-download id="1" dataset="[id]"])
  • Gravity Forms
    • Success Message
    • Email Notification Message
    • GravityView* ([e2pdf-download id="1" dataset="{entry_id}"])
  • Forminator
    • Success Message
    • Email Notification Message
  • Caldera Forms
    • Success Message
    • Email Notification Message
  • Divi Contact Forms
    • Success Message
    • Email Notification Message
  • WordPress
    • Page/Post Content
  • WooCommerce
    • Item set to "Products":
      • Product Description
      • Product File Download URL
      • Product Attribute Value
    • Item set to "Variations":
      • Variation Description
      • Variation File Download URL

Required Parameters

  • id - ID of the E2pdf Template to use.
    • Value: (int)
    • Usage: [e2pdf-download id="1"]
  • OR

  • pdf - Full path to static PDF.
    • Value: (string)
    • Usage: [e2pdf-download pdf="/home/pdfs/document.pdf"]

Optional Parameters

  • dataset - Static ID of "dataset" to use for which it must be generated PDF. If not set, dynamic dataset will be used depending on where shortcode placed.
    • Value: (mixed)
    • Usage: [e2pdf-download id="1" dataset="1"]
  • flatten - Overwrites PDF "Flatten" (readonly) option set inside E2Pdf Template.
    • Value: (int)
      • 0 - No flatten (editable fields):
      • 1 - Flatten (readonly fields):
      • 2 - Full flatten (PDF pages as images):
    • Usage: [e2pdf-download id="1" flatten="1"]
  • name - Overwrites "PDF Name" set inside E2Pdf Template.
    • Value: (string)
    • Usage: [e2pdf-download id="1" name="name"]
  • password - Overwrites "PDF Password" set inside E2Pdf Template.
    • Value: (string)
    • Usage: [e2pdf-download id="1" password="password"]
  • button-title - Overwrites link "Button Title"" set inside E2Pdf Template.
    • Value: (string)
    • Usage: [e2pdf-download id="1" button-title="Download"]
  • inline - Overwrites "Inline" option set inside E2Pdf Template to Download or View PDF in browser tab.
    • Value: (boolen) true or false
    • Usage: [e2pdf-download id="1" inline="true"]
  • auto - Overwrites "Auto download" option set inside E2Pdf Template to force autodownload when on page/form submited.
    • Value: (boolen) true or false
    • Usage: [e2pdf-download id="1" auto="true"]
  • format - Overwrites "Format" option set Inside E2Pdf Template to output PDF as:
    • Value: (string)
      • pdf - PDF:
      • jpg - JPG:
    • Usage: [e2pdf-download id="1" flatten="1" format="jpg"]
  • class - Additional classes to add to generated PDF Download Link.
    • Value: (string)
    • Usage: [e2pdf-download id="1" class="additional-class"]
  • arg1, arg2, arg3... - Add custom values to be accesable inside PDF while render.
    • Value: (string)
    • Usage: [e2pdf-download id="1" dataset="1" arg1="Custom Value 1" arg2="Custom Value 2"]
    • To output values inside E2Pdf Template: [e2pdf-arg key="arg1"], [e2pdf-arg key="arg2"], etc...
  • user_id - Define User ID for [e2pdf-user] shortcode.
    • Value: (int)
    • Usage: [e2pdf-download id="1" dataset="1" user_id="1"]
  • output - Custom output for shortcode.
    • Value: (string)
      • url - Output "href" value:
    • Usage: [e2pdf-download id="1" output="url"]

[e2pdf-attachment]

Shortcode applied to generate PDF and attach it to email.

Example:

[e2pdf-attachment id="1"]

Can be used inside:

  • Formidable Forms
    • Email Notification Message
  • Gravity Forms
    • Email Notification Message
  • Forminator
    • Email Notification Message
  • Caldera Forms
    • Email Notification Message
  • Divi Contact Forms
    • Email Notification Message
  • WordPress
    • MemberPress Email Notification Message* ("dataset" must be defined to Page/Post/Custom Post ID depending on "Item" set ([e2pdf-attachment id="1" dataset="123"])
  • WooCommerce
    • Item set to "Order":
      • Email Additional content
    • Item set to "Products":
      • Email Additional content
        • [e2pdf-attachment id="1"] - will generate and attach PDF for each "Product".
        • [e2pdf-attachment id="1" dataset="123"] - will generate and attach PDF only if "Product" with ID: 123 will be in "Order".
    • Item set to "Variations":
      • Email Additional content
        • [e2pdf-attachment id="1"] - will generate and attach PDF for each "Variation".
        • [e2pdf-attachment id="1" dataset="123"] - will generate and attach PDF only if "Variation" with ID: 123 will be in "Order".

Required

  • id - ID of the E2pdf Template to use.
    • Value: (int)
    • Usage: [e2pdf-attachment id="1"]
  • OR

  • pdf - Full path to static PDF
    • Value: (string)
    • Usage: [e2pdf-attachment pdf="/home/pdfs/document.pdf"]

Optional Parameters

  • dataset - Static ID of "dataset" to use for which it must be generated PDF. If not set, dynamic dataset will be used depending on where shortcode placed.
    • Value: (mixed)
    • Usage: [e2pdf-attachment id="1" dataset="1"]
    • Default: Current entry
  • flatten - Overwrites PDF "Flatten" (readonly) option set inside E2Pdf Template.
    • Value: (int)
      • 0 - No flatten (editable fields):
      • 1 - Flatten (readonly fields):
      • 2 - Full flatten (PDF pages as images):
    • Usage: [e2pdf-attachment id="1" flatten="1"]
  • name - Overwrites "PDF Name" set inside E2Pdf Template.
    • Value: (string)
    • Usage: [e2pdf-attachment id="1" name="name"]
  • password - Overwrites "PDF Password" set inside E2Pdf Template.
    • Value: (string)
    • Usage: [e2pdf-attachment id="1" password="password"]
  • format - Overwrites "Format" option set Inside E2Pdf Template to output PDF as:
    • Value: (string)
      • pdf - PDF:
      • jpg - JPG:
    • Usage: [e2pdf-attachment id="1" flatten="1" format="jpg"]
  • arg1, arg2, arg3... - Add custom values to be accesable inside PDF while render.
    • Value: (string)
    • Usage: [e2pdf-attachment id="1" arg1="Custom Value 1" arg2="Custom Value 2"]
    • To output values inside E2Pdf Template: [e2pdf-arg key="arg1"], [e2pdf-arg key="arg2"], etc...
  • user_id - Define User ID for [e2pdf-user] shortcode.
    • Value: (int)
    • Usage: [e2pdf-attachment id="1" dataset="1" user_id="1"]
  • apply - Required if called via custom call or via do_shortcode function
    Will output path to TMP PDF that was generated via shortcode.
    • Value: (boolen) true or false
    • Usage: [e2pdf-attachment id="1" dataset="1" apply="true"]

[e2pdf-save]

Shortcode applied to save file on server.

Example:

[e2pdf-save id="1"]

Can be used inside:

  • Formidable Forms
    • Success Message
    • Email Notification Message
  • Gravity Forms
    • Success Message
    • Email Notification Message
  • Forminator
    • Success Message
    • Email Notification Message
  • Caldera Forms
    • Success Message
    • Email Notification Message
  • Divi Contact Forms
    • Success Message
    • Email Notification Message

Required

  • id - ID of the E2pdf Template to use.
    • Value: (int)
    • Usage: [e2pdf-save id="1"]

Optional Parameters

  • dataset - Static ID of "dataset" to use for which it must be generated PDF. If not set, dynamic dataset will be used depending on where shortcode placed.
    • Value: (mixed)
    • Usage: [e2pdf-save id="1" dataset="1"]
    • Default: Current entry
  • flatten - Overwrites PDF "Flatten" (readonly) option set inside E2Pdf Template.
    • Value: (int)
      • 0 - No flatten (editable fields):
      • 1 - Flatten (readonly fields):
      • 2 - Full flatten (PDF pages as images):
    • Usage: [e2pdf-save id="1" flatten="1"]
  • name - Overwrites "PDF Name" set inside E2Pdf Template.
    • Value: (string)
    • Usage: [e2pdf-save id="1" name="name"]
  • password - Overwrites "PDF Password" set inside E2Pdf Template.
    • Value: (string)
    • Usage: [e2pdf-save id="1" password="password"]
  • dir - Path to save PDF files.
    Directory must exists and be writable. If attribute not set - default directory will be used:
    /wp-content/uploads/e2pdf/tpl/{Template ID}/save/
    To use relative path dir="wp-content/uploads/dir/"
    • Value: (string)
    • Usage: [e2pdf-save id="1" dir="/home/pdfs/"]
  • create_dir - Create DIR (if not exists)
    • Value: (boolen) true or false
    • Default: false
    • Usage: [e2pdf-save id="1" dir="wp-content/uploads/dir/" create_dir="true"]
  • create_index - Create index.php file (if not exists) to prevent PDfs list.
    • Value: (boolen) true or false
    • Default: true
    • Usage: [e2pdf-save id="1" dir="wp-content/uploads/dir/" create_index="false"]
  • create_htaccess - Create .htaccess file (if not exists) to prevent access.
    • Value: (boolen) true or false
    • Default: true
    • Usage: [e2pdf-save id="1" dir="wp-content/uploads/dir/" create_htaccess="false"]
  • download - Shortcode applied to generate PDF download link to saved PDF. Attributes from [e2pdf-download] shortcode can be applied.
    • Value: (boolen) true or false
    • Usage: [e2pdf-save id="1" download="true"]
  • attachment - Shortcode applied to generate PDF attachment from saved PDF. Attributes from [e2pdf-attachment] shortcode can be applied.
    • Value: (boolen) true or false
    • Usage: [e2pdf-save id="1" attachment="true"]
  • view - Shortcode applied to view PDF inside page via pdf.js with saved PDF. Attributes from [e2pdf-view] shortcode can be applied.
    • Value: (boolen) true or false
    • Usage: [e2pdf-save id="1" view="true"]
  • zapier - Shortcode applied to generate PDF Zapier Request from saved PDF. Attributes from [e2pdf-zapier] shortcode can be applied.
    • Value: (boolen) true or false
    • Usage: [e2pdf-save id="1" zapier="true"]
  • overwrite - Overwrite file if exists.
    • Value: (boolen) true or false
    • Usage: [e2pdf-save id="1" overwrite="true"]
  • format - Overwrites "Format" option set Inside E2Pdf Template to output PDF as:
    • Value: (string)
      • pdf - PDF:
      • jpg - JPG:
    • Usage: [e2pdf-save id="1" flatten="1" format="jpg"]
  • arg1, arg2, arg3... - Add custom values to be accesable inside PDF while render.
    • Value: (string)
    • Usage: [e2pdf-save id="1" arg1="Custom Value 1" arg2="Custom Value 2"]
    • To output values inside E2Pdf Template: [e2pdf-arg key="arg1"], [e2pdf-arg key="arg2"], etc...
  • user_id - Define User ID for [e2pdf-user] shortcode.
    • Value: (int)
    • Usage: [e2pdf-save id="1" dataset="1" user_id="1"]
  • apply - Required if called via custom call or via do_shortcode function
    Will output path to PDF that was generated via shortcode
    • Value: (boolen) true or false
    • Usage: [e2pdf-save id="1" dataset="1" apply="true"]

[e2pdf-view]

Shortcode applied to view PDF inside page via pdf.js viewer.

Example:

[e2pdf-view id="1" dataset="1" flatten="1" name="name" password="password" width="100%" height="500" class="additional-class"]

Can be used inside:

  • Formidable Forms
    • Success Message
    • Views* ([e2pdf-download id="1" dataset="[id]"])
  • Gravity Forms
    • Success Message
    • GravityView* ([e2pdf-download id="1" dataset="{entry_id}"])
  • Forminator
    • Success Message
  • Caldera Forms
    • Success Message
  • Divi Contact Forms
    • Success Message
  • WordPress
    • Page/Post Content
  • WooCommerce
    • Item set to "Products":
      • Product Description
    • Item set to "Variations":
      • Variation Description

Required

  • id - ID of the E2pdf Template to use.
    • Value: (int)
    • Usage: [e2pdf-view id="1"]
  • OR

  • pdf - Url to static PDF
    • Value: (string)
    • Usage: [e2pdf-view pdf="https://example.com/document.pdf"]
  • OR

  • pdf - Full path to static PDF
    • Value: (string)
    • Usage: [e2pdf-view pdf="/home/pdfs/document.pdf"]

Optional Parameters

  • dataset - Static ID of "dataset" to use for which it must be generated PDF. If not set, dynamic dataset will be used depending on where shortcode placed.
    • Value: (mixed)
    • Usage: [e2pdf-view id="1" dataset="1"]
    • Default: Current entry
  • flatten - Overwrites PDF "Flatten" (readonly) option set inside E2Pdf Template.
    • Value: (int)
      • 0 - No flatten (editable fields):
      • 1 - Flatten (readonly fields):
      • 2 - Full flatten (PDF pages as images):
    • Usage: [e2pdf-view id="1" flatten="1"]
  • name - Overwrites "PDF Name" set inside E2Pdf Template.
    • Value: (string)
    • Usage: [e2pdf-view id="1" name="name"]
  • password - Overwrites "PDF Password" set inside E2Pdf Template.
    • Value: (string)
    • Usage: [e2pdf-view id="1" password="password"]
  • format - Overwrites "Format" option set Inside E2Pdf Template to output PDF as:
    • Value: (string)
      • pdf - PDF:
      • jpg - JPG:
    • Usage: [e2pdf-view id="1" flatten="1" format="jpg"]
  • arg1, arg2, arg3... - Add custom values to be accesable inside PDF while render.
    • Value: (string)
    • Usage: [e2pdf-view id="1" arg1="Custom Value 1" arg2="Custom Value 2"]
    • To output values inside E2Pdf Template: [e2pdf-arg key="arg1"], [e2pdf-arg key="arg2"], etc...
  • user_id - Define User ID for [e2pdf-user] shortcode.
    • Value: (int)
    • Usage: [e2pdf-view id="1" dataset="1" user_id="1"]
  • width - Width of pdf.js viewer.
    • Value: (string)
    • Default: 100%
    • Usage: [e2pdf-view id="1" width="100%"]
  • height - Height of pdf.js viewer.
    • Value: (string)
    • Default: 500
    • Usage: [e2pdf-view id="1" height="500"]
  • responsive - Set pdf.js viewer to dynamic height.
    • Value: true or page
      • true - Fit pdf.js viewer to full PDF size.
      • page - Fit pdf.js viewer to first page PDF size.
    • Usage: [e2pdf-view id="1" responsive="true"]
  • class - Additional class to add to generated pdf.js iframe.
    • Value: (string)
    • Usage: [e2pdf-view id="1" class="additional-class"]
  • page - Move pdf.js to page on load.
    • Value: (int)
    • Usage: [e2pdf-view id="1" page="2"]
  • zoom - Set zoom on pdf.js load.
    • Value: (string) or (int)
      • (int)
      • page-width
      • page-height
      • page-fit
      • auto
    • Usage: [e2pdf-view id="1" zoom="100"]
  • nameddest - Go to a named destination on pdf.js load.
    • Value: (string)
    • Usage: [e2pdf-view id="1" nameddest="named"]
  • pagemode - Sidebar state on load
    • Value: (string)
      • none
      • thumbs
      • bookmarks
      • attachments
    • Usage: [e2pdf-view id="1" pagemode="thumbs"]
  • background - Define background for pdf.js viewer.
    • Value: (string)
    • Usage: [e2pdf-view id="1" background="#000"]
  • border - Define border for for pdf.js viewer.
    • Value: (string)
    • Usage: [e2pdf-view id="1" border="1px solid #fff"]
  • hide - Will hide elements of pdf.js viewer.
    • Value: (string)
      • toolbar
      • secondary-toolbar
      • left-toolbar
      • middle-toolbar
      • right-toolbar
      • sidebar
      • search
      • pageupdown
      • pagenumber
      • zoom
      • scale
      • presentation
      • openfile
      • openfile
      • print
      • download
      • bookmark
      • firstlastpage
      • rotate
      • cursor
      • scroll
      • spread
      • properties
    • Usage: [e2pdf-view id="1" hide="search,zoom"]
    • Multiple values can be set via comma.

[e2pdf-zapier]

Shortcode applied to generate data with PDF download link and send to Zapier via WebHook.

Example:

[e2pdf-zapier id="1" webhook="https://hooks.zapier.com/hooks/catch/1234567/ocfuhfo/"]

Can be used inside:

  • Formidable Forms
    • Success Message
    • Email Notification Message
  • Gravity Forms
    • Success Message
    • Email Notification Message
  • Forminator
    • Success Message
    • Email Notification Message
  • Caldera Forms
    • Success Message
    • Email Notification Message
  • Divi Contact Forms
    • Success Message
    • Email Notification Message

Required

  • id - ID of the E2pdf Template to use.
    • Value: (int)
    • Usage: [e2pdf-zapier id="1"]
  • OR

  • pdf - Full path to static PDF
    • Value: (string)
    • Usage: [e2pdf-zapier pdf="/home/pdfs/document.pdf"]

  • webhook - Zapier Webhook URL
    • Value: (int)
    • Usage: [e2pdf-zapier id="1" webhook="https://hooks.zapier.com/hooks/catch/1234567/ocfuhfo/"]

Optional Parameters

  • dataset - Static ID of "dataset" to use for which it must be generated PDF. If not set, dynamic dataset will be used depending on where shortcode placed.
    • Value: (mixed)
    • Usage: [e2pdf-zapier id="1" dataset="1"]
    • Default: Current entry
  • flatten - Overwrites PDF "Flatten" (readonly) option set inside E2Pdf Template.
    • Value: (int)
      • 0 - No flatten (editable fields):
      • 1 - Flatten (readonly fields):
      • 2 - Full flatten (PDF pages as images):
    • Usage: [e2pdf-zapier id="1" flatten="1"]
  • name - Overwrites "PDF Name" set inside E2Pdf Template.
    • Value: (string)
    • Usage: [e2pdf-zapier id="1" name="name"]
  • password - Overwrites "PDF Password" set inside E2Pdf Template.
    • Value: (string)
    • Usage: [e2pdf-zapier id="1" password="password"]
  • inline - Overwrites "Inline" option set inside E2Pdf Template to Download or View PDF in browser tab.
    • Value: (boolen) true or false
    • Usage: [e2pdf-zapier id="1" inline="true"]
  • format - Overwrites "Format" option set Inside E2Pdf Template to output PDF as:
    • Value: (string)
      • pdf - PDF:
      • jpg - JPG:
    • Usage: [e2pdf-zapier id="1" flatten="1" format="jpg"]
  • arg1, arg2, arg3... - Add custom values to be accesable inside PDF while render.
    • Value: (string)
    • Usage: [e2pdf-zapier id="1" dataset="1" arg1="Custom Value 1" arg2="Custom Value 2"]
    • To output values inside E2Pdf Template: [e2pdf-arg key="arg1"], [e2pdf-arg key="arg2"], etc...
  • user_id - Define User ID for [e2pdf-user] shortcode.
    • Value: (int)
    • Usage: [e2pdf-zapier id="1" dataset="1" user_id="1"]

[e2pdf-adobesign]

Shortcode can be used for uploading and creating agreements with Adobe Sign REST API.

Example:

[e2pdf-adobesign id="1"]

By default shortcode will do current API Calls :

or can be extended via filters:

Can be used inside:

  • Formidable Forms
    • Success Message
    • Email Notification Message
  • Gravity Forms
    • Success Message
    • Email Notification Message
  • Forminator
    • Success Message
    • Email Notification Message
  • Caldera Forms
    • Success Message
    • Email Notification Message
  • Divi Contact Forms
    • Success Message
    • Email Notification Message

Required

  • id - ID of the E2pdf Template to use.
    • Value: (int)
    • Usage: [e2pdf-adobesign id="1"]

Optional Parameters

  • dataset - Static ID of "dataset" to use for which it must be generated PDF. If not set, dynamic dataset will be used depending on where shortcode placed.
    • Value: (mixed)
    • Usage: [e2pdf-adobesign id="1" dataset="1"]
    • Default: Current entry
  • recipients - Recipients to send emails with PDF to.
  • flatten - Overwrites PDF "Flatten" (readonly) option set inside E2Pdf Template.
    • Value: (int)
      • 0 - No flatten (editable fields):
      • 1 - Flatten (readonly fields):
      • 2 - Full flatten (PDF pages as images):
    • Usage: [e2pdf-adobesign id="1" flatten="1"]
  • name - Overwrites "PDF Name" set inside E2Pdf Template.
    • Value: (string)
    • Usage: [e2pdf-adobesign id="1" name="name"]
  • password - Overwrites "PDF Password" set inside E2Pdf Template.
    • Value: (string)
    • Usage: [e2pdf-adobesign id="1" password="password"]
  • arg1, arg2, arg3... - Add custom values to be accesable inside PDF while render.
    • Value: (string)
    • Usage: [e2pdf-adobesign id="1" arg1="Custom Value 1" arg2="Custom Value 2"]
    • To output values inside E2Pdf Template: [e2pdf-arg key="arg1"], [e2pdf-arg key="arg2"], etc...
  • user_id - Define User ID for [e2pdf-user] shortcode.
    • Value: (int)
    • Usage: [e2pdf-adobesign id="1" dataset="1" user_id="1"]
  • disable - Disable DEFAULT (transientDocuments, agreements) API calls
    • Value:
      • post_transientDocuments - Disable upload request of PDF to Adobe Sign to get transientDocumentId
      • post_agreements - Disable create agreement request
    • Usage: [e2pdf-adobesign id="1" disable="post_transientDocuments,post_agreements"]

[e2pdf-exclude]

Exclude content from rendering inside PDF.

Example:

[e2pdf-exclude]content[/e2pdf-exclude]

Can be used inside:

  • WordPress
    • Page/Post Content
  • WooCommerce
    • Product Description
    • Variation Description



PDF Shortcodes


[e2pdf-user]

Output User Data/User Meta Data to PDFs.

Can be used inside: E2Pdf Templates

Example:

[e2pdf-user]
If "key" attribute not defined, ID will be outputed.
If "id" attribute not defined, it will be used User ID on PDF Link Generation moment.


Optional Parameters

  • id - Define User ID to output data. If not set - current User ID will be used to generate output.
    • Value:
      • (int) - Will output data for predefined User ID
      • current - Will output data ALWAYS for currently Logged In User ID
    • Usage: [e2pdf-user id="1"]
  • key - Output User Data/User Meta Data.
    • Value: (string)
      • ID - User ID
      • user_login - User Login
      • user_nicename - User Nicename
      • user_email - User Email
      • user_url - User URL
      • user_registered - User Registrated Time
      • display_name - User Display Name
      • custom_meta - Will search data inside User Meta with key 'custom_meta'
    • Usage: [e2pdf-user key="ID"]
  • meta - Force search only inside Meta Data.
    • Value: (boolen) true or false
    • Usage: [e2pdf-user key="custom_meta" meta="true"]

[e2pdf-format-number]

Apply number format to string

Can be used inside: E2Pdf Templates

Example:

[e2pdf-format-number decimal="2" dec_point="." thousands_sep="," explode="" implode=""]x[/e2pdf-format-number]

Required

  • x - String or Shortcode
    • Value: (mixed)
    • Usage: [e2pdf-format-number]10000000[/e2pdf-format-number]

Optional Parameters

  • decimal - Number of decimals
    • Value: (int)
    • Usage: [e2pdf-format-number decimal="2"]1000[/e2pdf-format-number]
  • dec_point - Decimal point used in number
    • Value: (string)
    • Usage: [e2pdf-format-number decimal="2" dec_point="."]1000[/e2pdf-format-number]
  • thousands_sep - Thousands separator
    • Value: (string)
    • Usage: [e2pdf-format-number thousands_sep=","]1000000[/e2pdf-format-number]
  • explode - Separator to explode string
    Shortcode parameters will be applied to each value that was separated
    • Value: (string)
    • Usage: [e2pdf-format-number explode=","]1000000,2000000[/e2pdf-format-number]
  • implode - Separator to implode exploded string
    Shortcode parameters will be applied to each value that was separated
    • Value: (string)
    • Usage: [e2pdf-format-number explode="," implode="|"]1000000,2000000[/e2pdf-format-number]

[e2pdf-format-date]

Apply date format to string

Can be used inside: E2Pdf Templates

Example:

[e2pdf-format-date format="Y-m-d H:i:s"]x[/e2pdf-format-date]

Required

  • x - String or Shortcode
    • Value: (mixed)
      • now - Current Datetime
      • time - UTC Datetime independed
      • current_time - Current Datetime returned by WordPress
    • Usage: [e2pdf-format-date]now[/e2pdf-format-date]

Optional Parameters

  • format - Date format in PHP date() function style
    • Value: (string)
    • Usage: [e2pdf-format-date format="Y-m-d H:i:s"]now[/e2pdf-format-date]
  • offset - Add or remove a set amount of time
    • Value: (string)
    • Usage: [e2pdf-format-date offset="+280 days"]now[/e2pdf-format-date]
  • function - Function to return Datetime
    • Value:
      • date_i18n - Use date_i18n() function
      • wp_date - Use wp_date() function
      • date - Use PHP date() function (default)
    • Usage: [e2pdf-format-date function="date_i18n"]now[/e2pdf-format-date]
  • gmt - Current time in UTC if current_time value used
    • Value: (boolen) true or false
    • Usage: [e2pdf-format-date function="date_i18n" gmt="true"]current_time[/e2pdf-format-date]
  • timezone - Adjust Datetime to defined Timezone with wp_date function
    • Value: (string)
    • Usage: [e2pdf-format-date function="wp_date" timezone="America/Los_Angeles" gmt="true"]current_time[/e2pdf-format-date]

[e2pdf-format-output]

Apply output format to string

Can be used inside: E2Pdf Templates

Example:

[e2pdf-format-output search="test" replace="test2" explode="," implode="." output="{0} - {1}" filter="trim"]x[/e2pdf-format-output]

Required

  • x - String or Shortcode
    • Value: (mixed)
    • Usage: [e2pdf-format-output]10000[/e2pdf-format-output]

Optional Parameters

  • explode - Separator to explode string
    Shortcode parameters will be applied to each value that was separated
    • Value: (string)
    • Usage: [e2pdf-format-output explode=","]1000000,2000000[/e2pdf-format-output]
  • implode - Separator to implode exploded string
    Shortcode parameters will be applied to each value that was separated
    • Value: (string)
    • Usage: [e2pdf-format-output explode="," implode="|"]1000000,2000000[/e2pdf-format-output]
  • search - Used for search to replace/ireplace value inside string
    For multiple search "|||" delimeter is used
    • Value: (string)
    • Usage: [e2pdf-format-output search="test" replace="test2"]test[/e2pdf-format-output]
  • replace - Replace all occurrences of the search string with the replacement string (Case-sensitive)
    For multiple replace "|||" delimeter is used
    • Value: (string)
    • Usage: [e2pdf-format-output search="test" replace="test2"]test[/e2pdf-format-output]
  • ireplace - Replace all occurrences of the search string with the replacement string (Case-insensitive)
    For multiple replace "|||" delimeter is used
    • Value: (string)
    • Usage: [e2pdf-format-output search="test" ireplace="test2"]test[/e2pdf-format-output]
  • substr - Return part of a string
    For setting start and length "," delimeter is used
    • Value: (int) or (int),(int)
    • Usage: [e2pdf-format-output substr="0,1"]test[/e2pdf-format-output]
  • output - Custom output for each exploded value
    'implode' parameter will be ignored in this case
    • Value: (string)
    • Usage: [e2pdf-format-output explode="," output="{0} - {1}"]1000000,2000000[/e2pdf-format-output]
  • filter - Filter value
    • Value: (string) or (string),(string),...
      • trim - Strip spaces at start/end of string
      • strip_tags - Remove html tags
      • strtolower - String to lowercase
      • strtoupper - String to uppercase
      • ucfirst - Uppercase first letter
      • lines - Remove empty lines
      • nl2br - New Lines to <BR>
      • wpautop - Apply WordPress wpautop filter
      • html_entity_decode - Decode HTML Entities
      • ireplace - Set the order of 'ireplace'. Will work only if 'search' and 'ireplace' argumtents is set
      • replace - Set the order of 'replace'. Will work only if 'search' and 'replace' argumtents is set
      • substr - Set the order of 'substr'. Will work only if 'substr' argumtent is set
    • Usage: [e2pdf-format-output explode="," filter="trim,ucfirst"] test , e2pdf [/e2pdf-format-output]

Elements


HTML

Supported Tags and Styles

  • <table>
    Supported attributes:
    • cellpadding
    • border
    • bordercolor
    • bgcolor
    • align
    • valign
    • width
  • <tr>
    Supported attributes:
    • cellpadding
    • border
    • bordercolor
    • bgcolor
    • align
    • valign
  • <td>
    Supported attributes:
    • colspan
    • align
    • bgcolor
  • <ul>
  • <ol>
  • <li>
  • <div>
  • <span>
  • <p>
  • <br>
  • <img>
  • <b>
  • <s>
  • <u>
  • <sub>
  • <sup>



Conditions


Conditions are designed to create dynamic PDFs depending on user input. With conditions you can change properties, hide or show elements/pages.

» To add conditions to element it's need to go to "Properties" of element (right mouse click) and at the bottom will be "Actions" section, where you can add/edit/remove condition actions.

» To add conditions to page it's need to go to "Properties" of page () and at the bottom will be "Actions" section, where you can add/edit/remove condition actions.

Action Parameters


Each element or page can have unlimited actions.

  • order - The order of action to fire
  • action - The action to fire
    • hide - hide element/page
    • show - show element/page
    • change - change property of element/page
  • property - The property to change. Available only if action set to "change". List of properties individual for each element/page.
  • change - Change selected property
    With number properties (width, height, top, left, etc) it's possible to use positive and negative numbers (+10, -20, etc), to have property change dynamically depending on current property value.
  • apply if - Apply action if:
    • any - any of conditions fit
    • all - all conditions fit

Condition Parameters


Each action can have unlimited conditions.

  • if - Value to compare. Can be used shortcodes inside
  • condition - Condition
    • = - equals
    • != - not equal
    • > - bigger
    • >= - bigger or equals
    • < - less
    • <= - less or equals
    • LIKE - if "if" contains "value"
    • NOT LIKE - if "if" doesn't contain "value"
  • value - Value to compare with. Can be used shortcodes inside


Actions & Filters


Actions & Filters can be applied to extend functionality of E2Pdf.

Filters


e2pdf_model_shortcode_e2pdf_adobesign_fileInfos

  • Location: /e2pdf/classes/model/e2pdf-shortcode.php
                    
add_filter('e2pdf_model_shortcode_e2pdf_adobesign_fileInfos', 'e2pdf_example_callback', '30', '6');
function e2pdf_example_callback($documents, $atts, $template, $entry, $extension, $file_path) {
      return $documents;
}

e2pdf_model_shortcode_e2pdf_adobesign_post_agreements_data

  • Location: /e2pdf/classes/model/e2pdf-shortcode.php
                    
add_filter('e2pdf_model_shortcode_e2pdf_adobesign_post_agreements_data', 'e2pdf_example_callback', '30', '7');
function e2pdf_example_callback($data, $atts, $template, $entry, $extension, $file_path, $documents) {
      return $data;
}

e2pdf_model_shortcode_e2pdf_adobesign_response

  • Location: /e2pdf/classes/model/e2pdf-shortcode.php
                    
add_filter('e2pdf_model_shortcode_e2pdf_adobesign_response', 'e2pdf_example_callback', '30', '8');
function e2pdf_example_callback($response, $atts, $template, $entry, $extension, $file_path, $documents, $agreement_id) {
      return $response;
}



Tips


It's possible to select separate multiple elements by holding CTRL key and click on different elements.

It's possible to remove elements with DELETE key.

After selecting elements it's possible to move them with keyboard arrows ( )

Element can be resized to by maximum size by set 999999 to width/height inside Object/Field "Properties".

It's possible to use Field Keys instead Field IDs with Formidable Forms extension by set option at "E2Pdf" » "Settings" » "Formidable"

It's possible to use show WooCommerce PDF button on "Cart"/"Checkout" page by selecting E2Pdf Template connected to "WooCommerce" -> "Cart" at "E2Pdf" » "Settings" » "WooCommerce"