[6.2] Generic Header template mod - 01/11/2003 4:54 PM
What does it do? It allows you to use a "Threads like" template for you generic header.
Why would you care?: Because you can take advantage of the new $tbopen and $tbclose variables in Threads 6.2...
Who gets the props?: Me (But I also have to give a nod to JustDave )
Here is the script for your Generic Header:
You also have to create a header.tmpl file and copy it to your ubbthreads/templates/default/ directory. Here is a simplified version of my header.tmpl file:
Since the last html tag in the tbopen.tmpl file is a table, all you have to do in your header.tmpl file after $tbopen is start out with a tr and a td tag.
The benefit to doing your header this way: If you ever change the tbopen or tbclose template files your header will automatically change...
P.S. Try this out on a forum header first. I have a test forum that I use to test new designs that only admins and mods can see.
Why would you care?: Because you can take advantage of the new $tbopen and $tbclose variables in Threads 6.2...
Who gets the props?: Me (But I also have to give a nod to JustDave )
Here is the script for your Generic Header:
Code
<br /> <br /> <? <br /> <br />$html = new html; <br /> <br />// Grab the tablewrapper <br />list($tbopen,$tbclose) = $html -> table_wrapper(); <br /> <br />// Send the template <br />include("$thispath/templates/$tempstyle/header.tmpl"); <br /> <br />?> <br /> <br />
You also have to create a header.tmpl file and copy it to your ubbthreads/templates/default/ directory. Here is a simplified version of my header.tmpl file:
Code
<br /> <? <br />echo <<<template <br /> <br />$tbopen <br /> <br /><tr> <br /><td class="darktable"> <br /><table border="0" cellpadding="0" cellspacing="0"> <br /> <br /><tr> <br /> <td class="logo-left"><img border="0" src="http://www.yourdomain.com/logo-clear.gif" width="250" height="60" /> <br /></td> <br /> <br /><td class="logo" width="100%" align="right"> <br /></td> <br /> <br /></tr> <br /> <br /></table> <br /></td> <br /></tr> <br /> <br />$tbclose <br /> <br /><br /> <br /> <br />template; <br />?> <br /> <br />
Since the last html tag in the tbopen.tmpl file is a table, all you have to do in your header.tmpl file after $tbopen is start out with a tr and a td tag.
The benefit to doing your header this way: If you ever change the tbopen or tbclose template files your header will automatically change...
P.S. Try this out on a forum header first. I have a test forum that I use to test new designs that only admins and mods can see.