Quote:
Originally Posted by cellarius
Too much information 
|
It was a lot better than reading video game manuals.
Quote:
Originally Posted by cellarius
There's no error in the code. You just changed the name of ine variable, and of course you are free to do so. The variables are just examples, you can name them whatever you want.
|
Yes, I'm aware of changing the variables to anything I want.
At first I was using your example to familiarize myself on how things work.
PHP Code:
$templater = vB_Template::create('mytemplate');
$templater->register('my_var', $my_var);
$templater->register('my_array', $my_array);
$mytemplate_rendered = $templater->render();
$templater = vB_Template::create('my_other_template');
$templater->register('my_template_rendered', $my_template_rendered);
print_output($templater->render());
The code above gave me a blank page because the var
$mytemplate_rendered = $templater->render();
did not match second argument in the register function.
$templater->register('my_template_rendered', $my_template_rendered);
So I changed this:
$templater->register('my_template_rendered', $my_template_rendered);
to:
$templater->register('my_template_rendered', $mytemplate_rendered);
And everything worked fine.
Quote:
Originally Posted by cellarius
The hook is there, if not, you have customized your FORUMHOME template and removed it. Anyway, this also is just an example; it works the same with any given template hook. Plus, I don't know why you think this belongs to the section where I write about preregistering - if you use a template hook, you don't need to preregister.
|
Pardon my ignorance since I'm still in developing stages of learning the functionality of how vb operates.
My guess is that I'm not fully understanding this particular option.
I've tried this on a clean install and was unable to locate this hook or maybe I'm just looking in the wrong place for it.
Additional guidance will very much be appreciated if you don't mind?
As for your last statement, I didn't not combine all of these options into one.
I created separate custom pages for each option just to see the results of each option listed.
The only one I had difficult understanding was the template hook option.