Quote:
Originally Posted by EquinoxWorld
Would you happen to know where I can find some documentation on what you just said.  That's exactly what I need to do. I have something that goes into a hook in forum home. I want to be able to put that hook on any other template or in a widget; can i do that?
|
A plugin from my paid registration mod (hook is
parse_templates):
PHP Code:
if (in_array(THIS_SCRIPT, array('register', 'payments'))) {
$template_hook['headinclude_javascript'] .= vB_Template::create('lancerforhire_paid_registration_head_include_script')->render();
}
The template
lancerforhire_paid_registration_head_include_scrip t for reference:
HTML Code:
<vb:if condition="!empty($vboptions['lancerforhire_paid_registration_jquery'])">
<script type="text/javascript" src="{vb:raw vboptions.lancerforhire_paid_registration_jquery}"></script>
</vb:if>
<script type="text/javascript">
<!--
$(document).ready(function() {
if (THIS_SCRIPT == 'register') {
$('.pre_registration_description').removeClass('hidden');
} else {
$('.post_registration_description').removeClass('hidden');
}
});
// -->
</script>