PHP Classes
elePHPant
Icontem

File: examples/beautifier/beautifier.php

Recommend this page to a friend!
  Classes of Christian Vigh  >  PHP RTF Tools  >  examples/beautifier/beautifier.php  >  Download  
File: examples/beautifier/beautifier.php
Role: Example script
Content type: text/plain
Description: Example script
Class: PHP RTF Tools
Parse and generate RTF documents using templates
Author: By
Last change: Modified the RtfDocument source to include the SearchableFile class, so that scripts will have to include only one file. Modified the examples accordingly
Date: 3 years ago
Size: 595 bytes
 

 

Contents

Class file image Download
<?php
   
/****************************************************************************************************
     *
     * This script uses the RtfStringBeautifier to beautify file "sample.rtf" and echoes the beautified
     * contents onto its standard output.
     *
     ****************************************************************************************************/

    
include ( '../../sources/RtfBeautifier.phpclass' ) ;

     if (
php_sapi_name ( ) != 'cli' )
        echo
"<pre>" ;

    
$pp = new RtfStringBeautifier ( file_get_contents ( 'sample.rtf' ) ) ;
     echo
$pp -> AsString ( ) ;