I'm creating a sidebar, an extensive one at that. Instead of adding it all to my index template, I went to "add template" pasted my sidebar html content and then named it "sideBar". Then I tried adding {$sideBar} and that did not work. What am I doing wrong?
You need to actually hook to index_end and define the variable there.
(2014-10-31, 10:00 PM)ErraticFox Wrote: [ -> ] (2014-10-31, 09:50 PM)coxuso Wrote: [ -> ]http://www.w3schools.com/php/php_variables.asp :-)
I know what variables are, I was talking about hooking to index_end
I don't know really any php, I can read it somewhat, but when it comes to making something, nada.
Bump. Could anyone please explain what dragonexpert meant?
Everything is stated in that post step by step.. If you activated the plugin, only step 3 and 4 are needed, nothing more.
(2014-11-04, 05:10 PM)ErraticFox Wrote: [ -> ] (2014-11-04, 01:35 PM)Destroy666 Wrote: [ -> ]http://community.mybb.com/thread-140152-...pid1008111
Alright, I figured that out. Now where would I put the variable to define "<template my_new_template>" to {$mynewtemplate} or something like that?
Destroy's method doesn't involve creating an actual variable like what you are trying to do. The <template my_new_template> is the variable. The template conditionals plugin adds the ability for you to add templates to templates without actually having to setup the variable yourself in PHP code.