1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25
| class ActionDisplay extends HTML_QuickForm_Action_Display
{
function _renderForm(&$page)
{
global $smarty;
global $renderer;
$this->page =& $page;
$smarty = & new Smarty;
$smarty->template_dir = './';
$smarty->compile_dir = '/tmp';
$renderer =& new HTML_QuickForm_Renderer_ArraySmarty($smarty);
$this->page->accept($renderer);
$smarty->assign('formdata', $renderer->toArray());
echo "<pre>";
var_dump($renderer->toArray());
echo "</pre>";
$smarty->display('QfSmarty.tpl');
}
} |
Partager