assign('add_ready', $addReady); $contentTemplate = $tpl->get_template($templateName); header('Content-type: application/x-javascript'); $tpl->display($contentTemplate);