dompdf_usage

Display command line usage.

Description

dompdf_usage(); 

Usage

  1. if ( !function_exists( 'dompdf_usage' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'woocommerce-pdf-invoices-packing-slips/lib/dompdf/dompdf.php'; 
  3.  
  4.  
  5. // NOTICE! Understand what this does before running. 
  6. $result = dompdf_usage(); 
  7.  

Defined (1)

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

/lib/dompdf/dompdf.php  
  1. function dompdf_usage() { 
  2. $default_paper_size = DOMPDF_DEFAULT_PAPER_SIZE; 
  3.  
  4. echo <<<EOD 
  5.  
  6. Usage: {$_SERVER["argv"][0]} [options] html_file 
  7.  
  8. html_file can be a filename, a url if fopen_wrappers are enabled, or the '-' character to read from standard input. 
  9.  
  10. Options: 
  11. -h Show this message 
  12. -l List available paper sizes 
  13. -p size Paper size; something like 'letter', 'A4', 'legal', etc.  
  14. The default is '$default_paper_size' 
  15. -o orientation Either 'portrait' or 'landscape'. Default is 'portrait' 
  16. -b path Set the 'document root' of the html_file.  
  17. Relative urls (for stylesheets) are resolved using this directory.  
  18. Default is the directory of html_file. 
  19. -f file The output filename. Default is the input [html_file].pdf 
  20. -v Verbose: display html parsing warnings and file not found errors. 
  21. -d Very verbose: display oodles of debugging output: everyframe 
  22. in the tree printed to stdout. 
  23. -t Comma separated list of debugging types (page-break, reflow, split) 
  24.  
  25. EOD; 
  26. exit;