2
here's how we created a printable ticket page in xhelp:
<?php
require('../../mainfile.php');
require_once XOOPS_ROOT_PATH.'/class/template.php';
$xoopsTpl = new XoopsTpl();
//Fill each necessary template var using $xoopsTpl->assign()
$tplname = 'db:'. $name_of_tpl_file;
$xoopsTpl->display($tplname);
?>
And the template was just like every other smarty template, except that it also has to write the HTML <head>, <body> tags:
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=<{$xoops_charset}>" />
<meta http-equiv="content-language" content="<{$xoops_langcode}>" />
<meta name="generator" content="XOOPS" />
<title>Page Title</title>
</head>
<body>
[b][color=008000]Page Content Goes Here[/color][/b]
</body>
</html>