From ed4b9fef172882fedf0520caf673eef87c97b055 Mon Sep 17 00:00:00 2001 From: Robert Sesek Date: Wed, 4 May 2005 06:19:55 +0000 Subject: [PATCH] r67: - Upping template system to use ISSO - Removing old files that are now handled by frameworks --- editcomment.php | 2 +- editreport.php | 12 +- global.php | 7 +- includes/db_mysql.php | 134 -------------- includes/functions.php | 14 +- includes/functions_mail.php | 100 ----------- includes/functions_template.php | 309 -------------------------------- includes/init.php | 4 +- index.php | 4 +- login.php | 2 +- newcomment.php | 2 +- newreport.php | 12 +- register.php | 4 +- search.php | 16 +- showreport.php | 4 +- 15 files changed, 40 insertions(+), 586 deletions(-) delete mode 100755 includes/db_mysql.php delete mode 100755 includes/functions_mail.php delete mode 100644 includes/functions_template.php diff --git a/editcomment.php b/editcomment.php index 7823c39..f15f697 100644 --- a/editcomment.php +++ b/editcomment.php @@ -98,7 +98,7 @@ if ($_REQUEST['do'] == 'edit') $comment['posttime'] = datelike('standard', $comment['dateline']); $comment['postby'] = construct_user_display($comment); $comment['comment'] = htmlspecialcharslike($comment['comment']); - eval('$tpl->flush("' . $tpl->fetch('editcomment') . '");'); + eval('$template->flush("' . $template->fetch('editcomment') . '");'); } /*=====================================================================*\ diff --git a/editreport.php b/editreport.php index c90fd10..8bd307a 100644 --- a/editreport.php +++ b/editreport.php @@ -118,7 +118,7 @@ if ($_REQUEST['do'] == 'edit') $value = $severity['severityid']; $selected = iff($severity['severityid'] == $bug['severity'], true, false); $label = $severity['severity']; - eval('$select[severity] .= "' . $tpl->fetch('selectoption') . '";'); + eval('$select[severity] .= "' . $template->fetch('selectoption') . '";'); } $show['changestatus'] = iff(can_perform('canchangestatus'), true, false); @@ -129,7 +129,7 @@ if ($_REQUEST['do'] == 'edit') $value = $priority['priorityid']; $selected = iff($priority['priorityid'] == $bug['priority'], true, false); $label = $priority['priority']; - eval('$select[priority] .= "' . $tpl->fetch('selectoption') . '";'); + eval('$select[priority] .= "' . $template->fetch('selectoption') . '";'); } foreach ($bugsys->datastore['status'] AS $status) @@ -137,7 +137,7 @@ if ($_REQUEST['do'] == 'edit') $value = $status['statusid']; $selected = iff($status['statusid'] == $bug['status'], true, false); $label = $status['status']; - eval('$select[status] .= "' . $tpl->fetch('selectoption') . '";'); + eval('$select[status] .= "' . $template->fetch('selectoption') . '";'); } foreach ($bugsys->datastore['resolution'] AS $resolution) @@ -145,7 +145,7 @@ if ($_REQUEST['do'] == 'edit') $value = $resolution['resolutionid']; $selected = iff($resolution['resolutionid'] == $bug['resolution'], true, false); $label = $resolution['resolution']; - eval('$select[resolution] .= "' . $tpl->fetch('selectoption') . '";'); + eval('$select[resolution] .= "' . $template->fetch('selectoption') . '";'); } } @@ -157,13 +157,13 @@ if ($_REQUEST['do'] == 'edit') $value = $dev['userid']; $selected = iff($dev['userid'] == $bug['assignedto'], true, false); $label = construct_user_display($dev, false); - eval('$select[dev] .= "' . $tpl->fetch('selectoption') . '";'); + eval('$select[dev] .= "' . $template->fetch('selectoption') . '";'); } } $pcv_select = construct_pcv_select("p$bug[productid]c$bug[componentid]v$bug[versionid]"); - eval('$tpl->flush("' . $tpl->fetch('editreport') . '");'); + eval('$template->flush("' . $template->fetch('editreport') . '");'); } /*=====================================================================*\ diff --git a/global.php b/global.php index 66c8063..bfa74d2 100755 --- a/global.php +++ b/global.php @@ -12,9 +12,6 @@ require_once('./includes/init.php'); -require_once('./includes/functions.php'); -require_once('./includes/functions_mail.php'); - // ################################################################### if ($bugsys->userinfo['userid']) @@ -23,8 +20,6 @@ if ($bugsys->userinfo['userid']) } // ################################################################### -require_once('./includes/functions_template.php'); -$tpl = new Template(); $globaltemplates = array( 'doctype', @@ -35,7 +30,7 @@ $globaltemplates = array( 'selectoptgroup' ); -$tpl->cache(array_merge($globaltemplates, (array)$fetchtemplates)); +$template->cache(array_merge($globaltemplates, (array)$fetchtemplates)); // ################################################################### // initialize template variables diff --git a/includes/db_mysql.php b/includes/db_mysql.php deleted file mode 100755 index 2c114a5..0000000 --- a/includes/db_mysql.php +++ /dev/null @@ -1,134 +0,0 @@ -link_id == 0) - { - if ($pconnect) - { - $this->link_id = @mysql_pconnect($server, $user, $password); - } - else - { - $this->link_id = @mysql_connect($server, $user, $password); - } - - if (!$this->link_id) - { - $this->throw('Link-Id == false, can not connect'); - return false; - } - - $candb = @mysql_select_db($this->database, $this->link_id); - if ($candb) - { - return true; - } - else - { - $this->throw('Cannot use the database ' . $this->database); - } - } - } - - function query($qstring) - { - $this->query_id = mysql_query($qstring, $this->link_id); - $this->current_query = $qstring; - $this->query_history[] = $this->current_query; - - if (!$this->query_id) - { - $this->throw('Invalid SQL query: ' . $this->current_query); - } - - return $this->query_id; - } - - function fetch_array($query_id) - { - return @mysql_fetch_array($query_id, MYSQL_ASSOC); - } - - function free_result($query_id) - { - @mysql_free_result($query_id); - $this->query_id = 0; - } - - function query_first($qstring) - { - $resource = $this->query($qstring); - $array = $this->fetch_array($resource); - $this->free_result($resource); - return $array; - } - - function insert_id() - { - return mysql_insert_id($this->link_id); - } - - function num_rows($query_id) - { - return @mysql_num_rows($query_id); - } - - function affected_rows() - { - return @mysql_affected_rows($this->link_id); - } - - function throw($message) - { - if ($this->link_id) - { - $this->error = mysql_error($this->link_id); - $this->errno = mysql_errno($this->link_id); - } - - echo "\r"; - echo "\r\r\r"; - echo "{$this->appname} Error\r\r\r\r\r

An error occured in {$this->appname}

\r\r

\r\t

\r\t\t»"; - echo "Query:\r\t\t
\r\t\t
{$this->current_query}
\r\t\t
\r\t\t»Error Number: "; - echo "{$this->errno}\r\t\t
\r\t\t
\r\t\t»Error Message: {$this->error}\r\t\t"; - echo "
\r\t\t
\r\t\t»File: $_SERVER[PHP_SELF]\r\t
\r

\r\r\r"; - - exit; - - } -} - -/*=====================================================================*\ -|| ################################################################### -|| # $HeadURL$ -|| # $Id$ -|| ################################################################### -\*=====================================================================*/ -?> \ No newline at end of file diff --git a/includes/functions.php b/includes/functions.php index 483f64b..7221bb9 100755 --- a/includes/functions.php +++ b/includes/functions.php @@ -115,7 +115,7 @@ function can_perform($bitmask, $userinfo = null) // NB: need to make sure we have the option to turn off just p/c selection without v function construct_pcv_select($select = '', $prefix = '     ') { - global $bugsys, $tpl; + global $bugsys; static $HTML; if ($HTML) @@ -152,7 +152,7 @@ function construct_pcv_select($select = '', $prefix = '    & $row['value'] = "{$valuepfx}c0v0"; $row['title'] = "$product[title]"; $row['description'] = ''; - eval('$HTML .= "' . $tpl->fetch('pcv_select_row') . '";'); + eval('$HTML .= "' . $bugsys->template->fetch('pcv_select_row') . '";'); $HTML .= construct_pcv_select_global_version($product['productid'], 0, $versions, $prefix, $select); if (is_array($versions["$product[productid]"])) { @@ -162,7 +162,7 @@ function construct_pcv_select($select = '', $prefix = '    & $row['value'] = "{$valuepfx}c0v$version[versionid]"; $row['title'] = $version['version']; $row['selected'] = iff($select == $row['value'], $selected, ''); - eval('$HTML .= "' . $tpl->fetch('pcv_select_row') . '";'); + eval('$HTML .= "' . $bugsys->template->fetch('pcv_select_row') . '";'); } } @@ -176,7 +176,7 @@ function construct_pcv_select($select = '', $prefix = '    & $row['selected'] = iff($select == $row['value'], $selected, ''); $row['title'] = $component['title']; $row['description'] = ''; - eval('$HTML .= "' . $tpl->fetch('pcv_select_row') . '";'); + eval('$HTML .= "' . $bugsys->template->fetch('pcv_select_row') . '";'); $HTML .= construct_pcv_select_global_version($component['componentmother'], $component['productid'], $versions, $prefix, $select); if (is_array($versions["$component[productid]"])) { @@ -187,7 +187,7 @@ function construct_pcv_select($select = '', $prefix = '    & $row['selected'] = iff($select == $row['value'], $selected, ''); $row['title'] = $version['version']; $row['description'] = ''; - eval('$HTML .= "' . $tpl->fetch('pcv_select_row') . '";'); + eval('$HTML .= "' . $bugsys->template->fetch('pcv_select_row') . '";'); } } } @@ -200,7 +200,7 @@ function construct_pcv_select($select = '', $prefix = '    & // ############ Start construct_pcv_select_global_version ############ function construct_pcv_select_global_version($product = 0, $component = 0, $versions = array(), $prefix = '', $select = '') { - global $tpl; + global $bugsys; if (is_array($versions['0'])) { foreach ($versions['0'] AS $version) @@ -211,7 +211,7 @@ function construct_pcv_select_global_version($product = 0, $component = 0, $vers $row['selected'] = iff($select == $row['value'], ' checked="checked"', ''); $row['title'] = $version['version']; $row['description'] = ''; - eval('$global_versions_html .= "' . $tpl->fetch('pcv_select_row') . '";'); + eval('$global_versions_html .= "' . $bugsys->template->fetch('pcv_select_row') . '";'); } } return $global_versions_html; diff --git a/includes/functions_mail.php b/includes/functions_mail.php deleted file mode 100755 index c2fa0ee..0000000 --- a/includes/functions_mail.php +++ /dev/null @@ -1,100 +0,0 @@ -options['webmasteremail']) - { - $fromemail = fetch_first_line($bugsys->options['webmasteremail']); - } - else - { - // Do we want a sender? - if ($fparam) - { - return false; - } - } - } - - // Work out the recipient - $toemail = fetch_first_line($toemail); - if (!$toemail) - { - return false; - } - - // Work out the subject - $subject = fetch_first_line($subject); - if (!$subject) - { - $subject = $bugsys->options['trackertitle'] . ' Notification'; - } - - // Work out the body - $message = convert_standard_line_breaks($message); - if (!$message) - { - return false; - } - - // Construct mail headers - $headers = convert_standard_line_breaks($headers, "\n"); - $headers .= "From: \"$fromemail\" <" . $bugsys->options['webmasteremail'] . ">\n"; - $headers .= "Return-Path: " . $bugsys->options['webmasteremail'] . "\n"; - $headers .= "X-Mailer: BugStrike [#]version[#] Mail\n"; - $headers .= "Content-Type: text/plain; charset=\"" . $bugsys->options['lang_charset'] . "\"\n"; - $headers .= "Content-Transfer-Encoding: 7bit\n"; - - if ($fparam) - { - mail($toemail, $subject, $message, trim($headers), "-f $fromemail"); - } - else - { - mail($toemail, $subject, $message, trim($headers)); - } -} - -// ###################### Start fetch_first_line ##################### -function fetch_first_line($text) -{ - $broken = explode("\r\n", convert_standard_line_breaks($text)); - return $broken[0]; -} - -// ################ Start convert_standard_line_breaks ############### -function convert_standard_line_breaks($text, $convert_to = "\r\n") -{ - return preg_replace("#(\r|\n|\r\n)#s", $convert_to, trim($text)); -} - -/*=====================================================================*\ -|| ################################################################### -|| # $HeadURL$ -|| # $Id$ -|| ################################################################### -\*=====================================================================*/ -?> \ No newline at end of file diff --git a/includes/functions_template.php b/includes/functions_template.php deleted file mode 100644 index 05afa3a..0000000 --- a/includes/functions_template.php +++ /dev/null @@ -1,309 +0,0 @@ -cache) > 0) - { - user_error('You cannot Template::cache() more than once per initialization', E_USER_WARNING); - } - else - { - foreach ($namearray AS $name) - { - $template = $this->_load($name); - $template = $this->_parse($template); - $this->cache["$name"] = $template; - } - } - } - - // ###################### Start Template::fetch ###################### - function fetch($name) - { - if (isset($this->cache["$name"])) - { - $template = $this->cache["$name"]; - } - else - { - $this->uncached[] = $name; - $template = $this->_load($name); - $template = $this->_parse($template); - } - - $this->usage["$name"]++; - - return $template; - } - - // ###################### Start Template::flush ###################### - function flush($template) - { - global $db; - - ob_start(); - - if (empty($template)) - { - user_error('Template::flush() produced no output', E_USER_WARNING); - exit; - } - - if (DEVDEBUG AND $_GET['query']) - { - if (is_array($db->query_history)) - { - echo '
';
-				foreach ($db->query_history AS $query)
-				{
-					echo $query . "\n\n
\n\n"; - } - echo '
'; - } - exit; - } - - if ($this->doneflush) - { - user_error('You cannot Template::flush() more than once per initialization', E_USER_WARNING); - exit; - } - - if (DEVDEBUG) - { - foreach ($this->usage AS $name => $count) - { - $optlist[] = '"; - } - - $debug .= "\r

\r\r"; - $debug .= "\r\t\r\t"; - $debug .= "\r\t\r\r\r\t
" . 'construct_debug_info_list()' . "$revisionTotal queries used: " . sizeof($db->query_history) . ""; - $debug .= "
"; - $debug .= "\r" . iff(is_array($this->uncached), sizeof($uncached) . " Uncached Template(s)\r
\r") . "\r

"; - - $template = str_replace('', "\r\r$debug\r\r\r", $template); - } - - print(stripslashes($template)); - } - - // ###################### Start Template::_load ###################### - function _load($name) - { - global $bugsys; - - if (($template = @file_get_contents("{$bugsys->options['ts_includepath']}$name.tpl")) !== false) - { - return $template; - } - else - { - echo "could not load template file {$bugsys->options['ts_includepath']}$name.tpl"; - exit; - } - } - - // ###################### Start Template::_parse ##################### - function _parse($template) - { - $template = stripslashes($template); - $template = str_replace('"', '\"', $template); - $template = $this->_parse_phrases($template); - $template = $this->_parse_conditionals($template); - return $template; - } - - // ################## Start Template::_parse_phrases ################# - function _parse_phrases($template) - { - $tag_start = ' - $close_of_open = strpos($phrase_bunch, $tag_start_end); - if ($close_of_open === false) - { - break; - } - - // Extract the opening tag so it can be parsed - $init_tag = substr($phrase_bunch, 0, ($close_of_open + strlen($tag_start_end))); - $init_tag = str_replace($tag_start, '', $init_tag); - $init_tag = substr($init_tag, 0, strlen($init_tag) - 1); - - // Get the args out of the tag - $args = preg_split('#([0-9].*?)=#', $init_tag); - foreach ($args AS $arg) - { - if ($arg AND $arg != ' ') - { - $arg = trim($arg); - $arg = substr($arg, 2); - $arg = substr($arg, 0, strlen($arg) - 2); - $arglist[] = $arg; - } - } - - // Just get the phrase name - $phrase_name = preg_replace('#(.*?)#i', '$2', $phrase_bunch); - - // Wrap the parsed data into the build function - $function_wrap = '" . construct_phrase(\'' . $phrase_name . '\', "' . implode('", "', $arglist) . '") . "'; - - // Replace the fully-parsed string back into the template - $template = substr_replace($template, $function_wrap, $location_start, $location_end + strlen($tag_end) - $location_start); - - unset($arglist); - } - - return $template; - } - - // ############### Start Template::_parse_conditionals ############### - function _parse_conditionals($template) - { - // Tag locations - $location_start = -1; - $location_end = -1; - - // Tag data - $tag_start = ' 1) - { - $location_start = $location_start + 1; - $location_end = $location_start + 2; - } - - // Strip out the opening ' 2) - { - user_error('Multiple else statements encountered while parsing conditionals in template', E_USER_WARNING); - } - - // Set the data - $iftrue = $data[0]; - $iffalse = $data[1]; - } - // Nope, reassign variables - else - { - $iftrue = $parsed; - $iffalse = null; - } - - // Put the condition and iftrue in the iff() function - $parsed_expression = '" . iff(' . stripslashes($expression_condition) . ',"' . $iftrue . '","' . $iffalse . '") . "'; - - // Parse the iff()'d expression back into the template data - $template = substr_replace($template, $parsed_expression, $location_start, $location_end + strlen($tag_end) - $location_start); - } - - // Repeat this process until it can't find any more - // expressions, then send back the parsed template data - // for final output - return $template; - } -} - -/*=====================================================================*\ -|| ################################################################### -|| # $HeadURL$ -|| # $Id$ -|| ################################################################### -\*=====================================================================*/ -?> \ No newline at end of file diff --git a/includes/init.php b/includes/init.php index b560b26..ecae7e0 100755 --- a/includes/init.php +++ b/includes/init.php @@ -178,7 +178,9 @@ if (!$templatesetid) // load the template system if (file_exists("./templates/$templateset[shortname]/tsinfo.php")) { - $bugsys->options['ts_includepath'] = "./templates/$templateset[shortname]/"; + $bugsys->load('template_fs'); + $template->extension = 'tpl'; + $template->templatedir = $bugsys->fetch_sourcepath("templates/$templateset[shortname]/"); } else { diff --git a/index.php b/index.php index fb44545..17a729d 100644 --- a/index.php +++ b/index.php @@ -44,14 +44,14 @@ while ($bug = $db->fetch_array($bugs_fetch)) $bug['status'] = $bugsys->datastore['status']["$bug[status]"]['status']; $bug['resolution'] = $bugsys->datastore['resolution']["$bug[resolution]"]['resolution']; $bug['lastpostinfo'] = datelike('standard', $bug['lastposttime']) . ' by ' . $bug['lastpost']; - eval('$bugs .= "' . $tpl->fetch('trackerhome_bits') . '";'); + eval('$bugs .= "' . $template->fetch('trackerhome_bits') . '";'); } $db->free_result($bugs_fetch); $show['newreport'] = iff(can_perform('cansubmitbugs'), true, false); -eval('$tpl->flush("' . $tpl->fetch('TRACKERHOME') . '");'); +eval('$template->flush("' . $template->fetch('TRACKERHOME') . '");'); /*=====================================================================*\ || ################################################################### diff --git a/login.php b/login.php index 387cb29..a618faa 100755 --- a/login.php +++ b/login.php @@ -28,7 +28,7 @@ if ($bugsys->userinfo['userid'] AND $_REQUEST['do'] != 'logout' AND $_POST['do'] if (empty($_REQUEST['do'])) { - eval('$tpl->flush("' . $tpl->fetch('login') . '");'); + eval('$template->flush("' . $template->fetch('login') . '");'); } // ################################################################### diff --git a/newcomment.php b/newcomment.php index c5ae26b..1ad78f7 100644 --- a/newcomment.php +++ b/newcomment.php @@ -72,7 +72,7 @@ if ($_REQUEST['do'] == 'add') exit; } - eval('$tpl->flush("' . $tpl->fetch('newcomment') . '");'); + eval('$template->flush("' . $template->fetch('newcomment') . '");'); } /*=====================================================================*\ diff --git a/newreport.php b/newreport.php index 78a78ec..b240ee3 100755 --- a/newreport.php +++ b/newreport.php @@ -154,7 +154,7 @@ if ($_REQUEST['do'] == 'add') { $value = $severity['severityid']; $label = $severity['severity']; - eval('$select[severity] .= "' . $tpl->fetch('selectoption') . '";'); + eval('$select[severity] .= "' . $template->fetch('selectoption') . '";'); } $show['changestatus'] = iff(can_perform('canchangestatus'), true, false); @@ -165,21 +165,21 @@ if ($_REQUEST['do'] == 'add') { $value = $priority['priorityid']; $label = $priority['priority']; - eval('$select[priority] .= "' . $tpl->fetch('selectoption') . '";'); + eval('$select[priority] .= "' . $template->fetch('selectoption') . '";'); } foreach ($bugsys->datastore['status'] AS $status) { $value = $status['statusid']; $label = $status['status']; - eval('$select[status] .= "' . $tpl->fetch('selectoption') . '";'); + eval('$select[status] .= "' . $template->fetch('selectoption') . '";'); } foreach ($bugsys->datastore['resolution'] AS $resolution) { $value = $resolution['resolutionid']; $label = $resolution['resolution']; - eval('$select[resolution] .= "' . $tpl->fetch('selectoption') . '";'); + eval('$select[resolution] .= "' . $template->fetch('selectoption') . '";'); } } @@ -191,13 +191,13 @@ if ($_REQUEST['do'] == 'add') { $value = $dev['userid']; $label = construct_user_display($dev, false); - eval('$select[dev] .= "' . $tpl->fetch('selectoption') . '";'); + eval('$select[dev] .= "' . $template->fetch('selectoption') . '";'); } } $pcv_select = construct_pcv_select(); - eval('$tpl->flush("' . $tpl->fetch('newreport') . '");'); + eval('$template->flush("' . $template->fetch('newreport') . '");'); } /*=====================================================================*\ diff --git a/register.php b/register.php index ae33eee..411c88f 100755 --- a/register.php +++ b/register.php @@ -37,10 +37,10 @@ if (empty($_REQUEST['do'])) foreach ($bugsys->datastore['language'] AS $value => $temp) { $label = $temp['title']; - eval('$opts .= "' . $tpl->fetch('selectoption') . '";'); + eval('$opts .= "' . $template->fetch('selectoption') . '";'); } - eval('$tpl->flush("' . $tpl->fetch('register') . '");'); + eval('$template->flush("' . $template->fetch('register') . '");'); } // ################################################################### diff --git a/search.php b/search.php index 5f0862a..b7d6d93 100644 --- a/search.php +++ b/search.php @@ -219,10 +219,10 @@ if ($_REQUEST['do'] == 'results') $bug['resolution'] = $bugsys->datastore['resolution']["$bug[resolution]"]['resolution']; $bug['lastpostinfo'] = datelike('standard', $bug['lastposttime']) . ' by ' . $bug['lastpost']; $bug['urladd'] = "&hilight=$hilight"; - eval('$bugs .= "' . $tpl->fetch('trackerhome_bits') . '";'); + eval('$bugs .= "' . $template->fetch('trackerhome_bits') . '";'); } - eval('$tpl->flush("' . $tpl->fetch('search_results') . '");'); + eval('$template->flush("' . $template->fetch('search_results') . '");'); // print_r($querybuild); } @@ -240,7 +240,7 @@ if ($_REQUEST['do'] == 'search') { $value = $severity['severityid']; $label = $severity['severity']; - eval('$select[severity] .= "' . $tpl->fetch('selectoption') . '";'); + eval('$select[severity] .= "' . $template->fetch('selectoption') . '";'); } $select['priority'] = $blankselect; @@ -248,7 +248,7 @@ if ($_REQUEST['do'] == 'search') { $value = $priority['priorityid']; $label = $priority['priority']; - eval('$select[priority] .= "' . $tpl->fetch('selectoption') . '";'); + eval('$select[priority] .= "' . $template->fetch('selectoption') . '";'); } $select['status'] = $blankselect; @@ -256,7 +256,7 @@ if ($_REQUEST['do'] == 'search') { $value = $status['statusid']; $label = $status['status']; - eval('$select[status] .= "' . $tpl->fetch('selectoption') . '";'); + eval('$select[status] .= "' . $template->fetch('selectoption') . '";'); } $select['resolution'] = $blankselect; @@ -264,7 +264,7 @@ if ($_REQUEST['do'] == 'search') { $value = $resolution['resolutionid']; $label = $resolution['resolution']; - eval('$select[resolution] .= "' . $tpl->fetch('selectoption') . '";'); + eval('$select[resolution] .= "' . $template->fetch('selectoption') . '";'); } $select['dev'] = $blankselect; @@ -272,10 +272,10 @@ if ($_REQUEST['do'] == 'search') { $value = $dev['userid']; $label = construct_user_display($dev, false); - eval('$select[dev] .= "' . $tpl->fetch('selectoption') . '";'); + eval('$select[dev] .= "' . $template->fetch('selectoption') . '";'); } - eval('$tpl->flush("' . $tpl->fetch('search') . '");'); + eval('$template->flush("' . $template->fetch('search') . '");'); } /*=====================================================================*\ diff --git a/showreport.php b/showreport.php index 31dfb36..94cd427 100644 --- a/showreport.php +++ b/showreport.php @@ -113,7 +113,7 @@ while ($comment = $db->fetch_array($comments_fetch)) } } - eval('$comments .= "' . $tpl->fetch('showreport_comment') . '";'); + eval('$comments .= "' . $template->fetch('showreport_comment') . '";'); } if (can_perform('canpostcomments')) @@ -135,7 +135,7 @@ if (is_array($hilight)) } } -eval('$tpl->flush("' . $tpl->fetch('SHOWREPORT') . '");'); +eval('$template->flush("' . $template->fetch('SHOWREPORT') . '");'); /*=====================================================================*\ || ################################################################### -- 2.22.5