PreparePreText

The Gravity PDF PreparePreText function.

Description

PreparePreText( $text, (string) $ff = '//FF//' ); 

Parameters (2)

0. $text
The text.
1. $ff — Optional. (string) => '//FF//'
The ff.

Usage

  1. if ( !function_exists( 'PreparePreText' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'gravity-pdf/vendor/blueliquiddesigns/mpdf/includes/functions.php'; 
  3.  
  4. // The text. 
  5. $text = null; 
  6.  
  7. // The ff. 
  8. $ff = '//FF//'; 
  9.  
  10. // NOTICE! Understand what this does before running. 
  11. $result = PreparePreText($text, $ff); 
  12.  

Defined (1)

The function is defined in the following location(s).

/vendor/blueliquiddesigns/mpdf/includes/functions.php  
  1. function PreparePreText($text, $ff='//FF//') { 
  2. $text = htmlspecialchars($text); 
  3. if ($ff) { $text = str_replace($ff, '</pre><formfeed /><pre>', $text); } 
  4. return ('<pre>'.$text.'</pre>');