I am going to need some help with this. I hope what I need isn't too complicated. To start, I'm modeling it after this type of page I saw on JC's site: JC's Page
Notice how the Threads navigation bars (ubbt_(un)registerednav.tmpl and ubbt_footer.tmpl) are absent? That's how I need mine. His also uses the forums header and footers in the includes folder. I've figured out how to do that. What I need now is to make it so the page I'm writing calls the Threads stylesheet, either the default or the one the user has specified in their profile.
The way I have this so far, I know that it will at the very least update dynamically when I edit the headers and footers from the threads admin area. The last thing I need is for this to call the threads stylesheet as well as the users language preference. I'm guessing that any language strings I write would need to go into the generic.php language file.
Please take a look at what I've got so far and let me know how I can take care of the language and stylesheet issue. Thanks!
EDIT: Here's the link to what I have so far: My test page
An easy way to "shut off" the menu bar on pages as needed....
I don't have files in front of me - so I'll speak generally - and that'll probably get you going in the right direction.
IN ubbt.inc.php - where it includes the ubbt_registerednav.tmpl file
Add an if clause around it, like this:
if (!$config['menubar']) { // include the template here }
Basically that says if there's no value for $config['menubar'] then print the menu. Since that variable doesn't exist in the config file - it'll always print.
Then on the page where you DON'T want the menu to appear - add this above the send_header function.
$config['menubar'] = 1;
This defines it as "1" BEFORE the header is sent. Since $config is a global variable, the send_header() function will "see it" and when it gets to that "if" statement you added, now there will be a value, and it won't include the nav bar template.
(This is similar to how we shut the sidebar off on certain pages).
You shoudl be able to apply that to each nav bar, and to the footer template.
I'll give that suggestion a whirl. It might be easier to modify the existing generic threads page mod, adding that line, $config['menubar'] = 1; and then just edit the html tags so that the content isn't in a table cell, but rather on the page itself, on top of whatever background color is called in the stylesheet.
Easy peasy.. Surprised it hasn't been copied yet..lol [/] I certainly feel smart now
Wait, how does using display:none remove the menubar from only that page (and a couple others), but not in the forums? I mean, if it's just one template, wouldn't the menu bar not appear in all pages?
Clearly the style tag at the end is all important, as well as the span tag that contains all the html for the menu bar. What I'm confused on is that if you added that span tag to your ubbt_registerednav.tmpl, then the menu bar wouldn't appear on any page at all.
Does your page call a different ubbt_registerednav.tmpl type file?
Thanks Josh! I've followed your suggestion about editing the ubbt.inc.php file and it worked. I've applied your suggestion t eliminate both registered and unregistered nav bars as well as the footer: http://www.laondalatina.com/foros/generic.php
Donate to UBBDev today to help aid in Operational, Server and Script Maintenance, and Development costs.
Please also see our parent organization VNC Web Services if you're in the need of a new UBB.threads Install or Upgrade, Site/Server Migrations, or Security and Coding Services.