Skip to content

Creating a custom script

CaMer0n edited this page Apr 12, 2013 · 2 revisions

When a plugin is more than you need and you wish to simply convert an existing PHP script for use with e107. Creating a custom-script manually may be the better option. Below is a simple example of a 'Hello World' - a file created in the root directory of e107.

<?php

require_once("class2.php"); // Load e107  
require_once(HEADERF);   // Load and output the theme's HTML for the $HEADER. 
    
$ns = e107::getRender(); // Load rendering object. 
$ns->tablerender("My Caption", "Hello World");  // Render Caption and Text according to Theme style. 

require_once(FOOTERF);   // Load and output the theme's HTML for the $FOOTER. 
exit; 

?>