<?php
//Include the class
include "Tamplate.class.php";
//Create a new instance of the class
$tamplate = new Tamplate();
//You can set the variables individually or as an array
//INDIVIDUALLY
//Set the variables
$tamplate->set_var("title", "Example site");
$tamplate->set_var("heading", "The example site");
$tamplate->set_var("message", "Welcome to my example site, I hope you enjoy it");
//AS AN ARRAY
//$tamplate->set_var(array("title" => "Example site", "heading" => "The example site", "mesage" => "Welcome to my example site, I hope you enjoy it"));
//Show the teamplate
$tamplate->show("test.tam");
?>
|