PHP Classes

File: example_1.php

Recommend this page to a friend!
  Classes of Valics Lehel   Fast Template   example_1.php   Download  
File: example_1.php
Role: Example script
Content type: text/plain
Description: example 1
Class: Fast Template
Updated revision of CDI Fast Template engine
Author: By
Last change: small changes
Date: 17 years ago
Size: 897 bytes
 

Contents

Class file image Download
<?
// Example FastTemplate Demo #1 - The example from the man page
// $Id: example_1.php,v 1.5 2006/02/14 12:27:33 paul Exp $
Header("Content-type: text/html");


include(
"cls_fast_template.php");
$ft = new FastTemplate("./templates");
$ft->php_in_html(true);
$ft->REWRITE_SRC_PATH="www.google.com/";
$time1=$ft->utime();
$ft->define(
    array(
       
'main' => "main.html",
       
'table' => "table.html",
       
'row' => "row.html"
   
)
);
$ft->assign( array("TITLE"=> "FastTemplate Test") );
for (
$n=1; $n <= 3; $n++)
{
   
$Number = $n;
   
$BigNum = $n*10;
   
$ft->assign(
        array(
           
'NUMBER' => $Number,
           
'BIG_NUMBER' => $BigNum
       
)
    );
   
$ft->parse("ROWS",".row");
}
$ft->showDebugInfo(1);
$ft->parse("MAIN", array("table","main"));
print (
$ft->utime()-$time1."\n");
$ft->FastPrint();
exit;
?>