PHP Classes

File: examples/example5.php

Recommend this page to a friend!
  Classes of Full name  >  x64Template Engine  >  examples/example5.php  >  Download  
File: examples/example5.php
Role: Example script
Content type: text/plain
Description: Example
Class: x64Template Engine
Template engine extensible with plug-in classes
Author: By
Last change: Changed include paths to reflect folder change
Date: 10 years ago
Size: 851 bytes


Class file image Download


//We start the object
$tpl=new x64Template();

//We set some values
$tpl->set("title","x64Template - Plugins example");
$tpl->set("keywords","x64Template, plugins example");
$tpl->set("description","x64Template - example using a simple PHP code highlighter plugin");

//If the user sent some PHP code then we add it
// note that the third param tells the engine to look up for 'if' tags
$tpl->set("code",(isset($_POST['code']))? htmlentities($_POST['code']) : '',true);

//And now we add the plugin

//Now we tell the class to parse a file