<?PHP
if (!isset($rootpath))
$rootpath="../";
include_once($rootpath . "common.php");
$ttem = new Template();
$ttem->set_filenames(array("header"=>$rootpath."html/header.tpl"));
$ttem->set_filenames(array("body"=>$rootpath."html/contactus/contactform.html"));
$ttem->set_filenames(array("footer"=>$rootpath."html/footer.tpl"));
$ttem->assign_var("SITE_TITLE", "Rabbitbb.com - Contact Us");
$ttem->assign_var("APP_ROOT", $webappcfg['APPPATH']);
@reset($rb);
while (list($key, $var) = each($rb))
{
$ttem->assign_var($key, $var);
}
@reset($rb);
while (list($key, $var) = each($rb))
{
$ttem->assign_var($key, $var);
}
if (isset($response['formerror']))
{
@reset($response['formerror']);
foreach($response['formerror'] as $key=>$value)
{
$_tassign = "";
for ($i=0; $i<count($value); $i++)
{
$_tassign = $rb[$value[$i]];
$ttem->assign_var("ERROR_" . strtoupper($key), $_tassign);
}
}
}
if (isset($response['formvalue']))
{
@reset($response['formvalue']);
foreach($response['formvalue'] as $key=>$value)
{
$ttem->assign_var("VALUE_" . strtoupper($key), $value);
}
}
if (isset($response['error']) && (isset($rb[$response['error']])))
$ttem->assign_var("ERRORMSG", $rb[$response['error']]);
$ttem->pparse("header");
$ttem->pparse("body");
$ttem->pparse("footer");
?>