Switch the 'modify' code of admin/field.php to use templates
[bugdar.git] / help.php
index c22ba31dce5225e6c673509bd3f15d0b33d95deb..29ed753dfc49b9be02d9e7f07156b385a4d3f63e 100644 (file)
--- a/help.php
+++ b/help.php
@@ -2,7 +2,7 @@
 /*=====================================================================*\
 || ###################################################################
 || # Bugdar
-|| # Copyright ©2002-2007 Blue Static
+|| # Copyright (c)2004-2009 Blue Static
 || #
 || # This program is free software; you can redistribute it and/or modify
 || # it under the terms of the GNU General Public License as published by
@@ -23,27 +23,22 @@ $fetchtemplates = array(
        'help_window'
 );
 
-define('SVN', '$Id$');
 
 require_once('./global.php');
 
-if (!$bugsys->in['topic'] OR !isset($bugsys->datastore['help'][ $bugsys->in['topic'] ]))
+if (!$input->in['topic'] OR !isset(bugdar::$datastore['help'][ $input->in['topic'] ]))
 {
        $topic['title'] = T('Invalid');
        $topic['body'] = T('That help topic does not exist in the system.');
 }
 else
 {
-       $topic = $bugsys->datastore['help'][ $bugsys->in['topic'] ];
+       $topic = bugdar::$datastore['help'][ $input->in['topic'] ];
        $topic['body'] = nl2br($topic['body']);
 }
 
-eval('$template->flush("' . $template->fetch('help_window') . '");');
+$tpl = new BSTemplate('help_window');
+$tpl->vars = array('topic' => $topic);
+$tpl->evaluate()->flush();
 
-/*=====================================================================*\
-|| ###################################################################
-|| # $HeadURL$
-|| # $Id$
-|| ###################################################################
-\*=====================================================================*/
 ?>
\ No newline at end of file