New Articles

  1. sgapiSetFontPDF(%%pdf, %%font, %%style)

    This function sets the font and style of the given pdf (%%font is "Helvetica" and %%style is "Null" by default). %%font options %%style options 'adobearabic' 'BoldItalic','Italic','Bold' 'adobehebrew' 'BoldItalic','Italic','Bold' ...
  2. sgapiTablePDF(%%pdf, %%data, %%cols, %%title, %%options)

    This function adds a table to the given PDF. Parameters %%pdf - The title of the PDF you are creating. %%data = array() - The array of data to include in the table. %%cols= array() - The array of column headers. %%title - The table t...
  3. sgapiTextPDF(%%pdf, %%text, %%size, %%options, %%test)

    This function adds text to the given PDF. Parameters %%pdf - The title of the PDF you are creating. %%text - The text to add to the PDF. %%size - The font size (default is 12 ). %%option = array () - 'left' => number - gap to leav...
  4. sgapiSetColorPDF(%%pdf, %%r, %%g, %%b)

    This function sets the text color for the given pdf.  %%r, %%g, %%b are set to 0 (black) by default. For more info on PHP PDF Creation visit: https://github.com/rospdf/pdf-php/blob/master/readme.pdf Example The below script creates and build...
  5. sgapiImagePDF(%%pdf, %%image, %%pad, %%width, %%resize, %%just, %%border)

    This function adds an image to the given PDF. Parameters %%pdf - The title of the PDF you are creating. %%image - The image URL. %%pad - Image padding by page unit (defaults to 5). Enter '0' for no padding. %%width - The width of the...
  6. sgapiHTMLTOPDF(%%contents, %%landscape, %%border)

    Converts the HTML provided in %%contents to a PDF file. %%landscape and %%borders parameters are boolean values and are optional. By default, the %%border parameter is true, and the %%landscape parameter is false. The %%border parameter wi...
  7. sgapiNewPagePDF(%%pdf)

    This function creates a new page in the given pdf. For more info on PHP PDF Creation visit: https://github.com/rospdf/pdf-php/blob/master/readme.pdf Example The below script can be included when building a PDF object to start a...
  8. PDF Functions

    The PDF functions allow you to build a PDF within a response to be sent via the sgapiEmailSend function. PHP PDF Creation - Use these functions to dynamically create a PDF document using PHP. PDFs can be output and attached to an email ...
  9. sgapiNewPDF(%%pdf, %%paper, %%orientation)

    This function creates a PDF object that you can store, build and output and send via the sgapiEmailSend function.  Parameters %%pdf - The title of the PDF you are creating. %%paper - The paper size, e.g. 'letter', 'legal', 'a4' (%%paper is...
  10. sgapiRemoveContactFromInvite(%%linkID, %%email)

    This function removes the given contact from the given invite as specified by %%linkID. linkID is the inviteID and can be found in your email campaign. Example In this example, we'll remove a contact from the email campaign with ID 1234...