Never mind, fixed it.

I've been trying to figure out how to have options in my template engine like: {language=english} or something like that. The option needs to be turned into a PHP variable for use elsewhere. Here's the template engine and implementation:
Template Engine Class
class Page
{
// Start $page variable for easy use
var $page;
// Make the template path easier to read and write

$current_theme_dir = $theme_dir.$current_theme.'/';
function Page($template) {
if (file_exists($current_theme_dir.$template.'.template.html'))
$this->page = join("", file($current_theme_dir.$template.'.template.html'));
else
die("Template file $template not found.");
}
// File parser function
function parse($file) {
ob_start();
$file = $current_theme_dir.$file.'.template.html';
include($file);
$buffer = ob_get_contents();
ob_end_clean();
return $buffer;
}
// Tag replacer function
function replace_tags($tags = array()) {
if (sizeof($tags) > 0) {
foreach ($tags as $tag => $data) {
$data = (file_exists($data)) ? $this->parse($data) : $data;
$this->page = eregi_replace("{" . $tag . "}", $data, $this->page);
}
}
else {
die("No tags designated for replacement.");
}
}
// Function to output the page to the browser
function output() {
echo $this->page;
}
}
Implementation
// This function compiles and loads themes
function loadTemplate(strtolower(ucwords($input))) {
// Start up the template compiler!
require_once('TemplateCompiler.php');
$page = new Page($input);
// Replace the tags and send it out!
loadLanguage($current_language);
$page->replace_tags(array(
"title" => "Test"
));
return $output;
}
[/s]