Login   Register  
PHP Classes
elePHPant
Icontem

File: sample.php

Recommend this page to a friend!
Stumble It! Stumble It! Bookmark in del.icio.us Bookmark in del.icio.us
  Classes of Chris Lam  >  Booster Template  >  sample.php  >  Download  
File: sample.php
Role: Example script
Content type: text/plain
Description: sample usage of the class
Class: Booster Template
Compiled template engine
Author: By
Last change: n/a
Date: 2008-07-01 04:42
Size: 361 bytes
 

Contents

Class file image Download
<?php

function booster_lang($token)
{
    return 
ucwords(str_replace('_'' '$token));
}

require_once 
'Booster.class.php';

$b = new Booster();

// Variables to be used within the loaded template
$data = array(
    
'abc' => 123.269,
    
'rows' => array('peter''Christopher''Ben''Chris')
);

// Load the template
$b->load('test'$data);

?>