PHP Classes

File: index.php

Recommend this page to a friend!
  Classes of Thiago Arcanjo   FileText   index.php   Download  
File: index.php
Role: Application script
Content type: text/plain
Description: Initialize your app/site
Class: FileText
Generate Web pages from template files
Author: By
Last change: FileText as updated.
Version 2.0.0
Change file languages place and format.
Added PHPDoc tags.
Date: 8 years ago
Size: 820 bytes
 

Contents

Class file image Download
<?php
/**
 * FileText
 *
 * This class can generate Web pages from template files.
 * It can read template files for page header, footer, body and replace tags with template variable values.
 * The class executes the processed template result as PHP script, so it can generate the final page output.
 *
 * @package FileText
 *
 * @author Thiago Arcanjo <thiago@thiagoarcanjo.com.br>
 * @version 2.0.0
 *
 */
 
// SESSION START
@session_start();

// CONFIG
include('settings.php');

$FileText = new FileText; // Texts
$Tpl = new Tpl; // Views

// GENERAL TEXTS
$Tpl->setTag('TITLE',TITLE);
$Tpl->setTag('FOOTER',FOOTER);
$Tpl->setTag('PAGES_TPL',PAGES_TPL);
$Tpl->setTag('CHARSET',CHARSET);

$Tpl->setTag('PAGE','home');
$_SESSION["PAGE"] = 'home';

$FileText->makeTPL($Tpl,'home');

$Tpl->open('home');

$Tpl->show();
?>