PHP Classes

File: sample_1.php

Recommend this page to a friend!
  Classes of Bao Nguyen Quoc   Basic Template   sample_1.php   Download  
File: sample_1.php
Role: Example script
Content type: text/plain
Description: Example 1
Class: Basic Template
Regular expression matching based template engine
Author: By
Last change:
Date: 19 years ago
Size: 484 bytes
 

Contents

Class file image Download
<?

include_once "basic_template.php";

$template = new basic_template;

$template->dir = '.';

$template->set('news_headline' , 'Basic Template Example');
$template->set('news_author' , 'Quoc Bao');
$template->set('news_author_mail' , 'quocbao.coder@gmail.com');
$template->set('news_lite_content' , 'Basic example');
$template->set('news_content' , "Hello , this is a very easy example<br>\n");

$template->output('sample_1.html');

echo
$template->result;

?>