PHP Classes

File: example_tabular.php

Recommend this page to a friend!
  Classes of Gianluca Zanferrari   abc template   example_tabular.php   Download  
File: example_tabular.php
Role: Example script
Content type: text/plain
Description: example tabular
Class: abc template
Template engine that replaces tags in PHP scripts
Author: By
Last change:
Date: 12 years ago
Size: 593 bytes


Class file image Download
* this is an example with tabular data like data from a database; it is passed as multidimensional array where:
* in the 1st level are given the tags to be replaced.
* in the 2nd level the values.

* template processor
$page = new Page("row.html");

$id[] = $i;

* here we go; replace all placeholders
'id' => $id
,'name' => array('john','mary','susy','bob')
'age' => array('22','45','67','89')