TinyPortal

Development => Support => Topic started by: atlantisrising on November 26, 2008, 03:19:36 AM

Title: Hide panels custom help
Post by: atlantisrising on November 26, 2008, 03:19:36 AM
I posted this over at the smf site.  I think this bit of the code is my issue but I don't know what to do about it.

QuoteI am trying to modify my new theme, there is a piece of code that is apparently essential to get TP blocks out of my blogs.  For some reason, I keep getting an unexpected T-string error. 

I'm running TPv1.0.6, SMF 1.1.6, Blog Community 2.0.2

The bit of code giving me a headache is:

';
// TinyPortal
if($context['TPortal']['leftbar'])
             echo '<td style="padding-left: 1ex;"><a href="javascript:void(0);" onclick="shrinkHeaderLeftbar(!current_leftbar); return false;"><img id="upshrinkLeftbar" src="', $settings['images_url'], '/', empty($options['collapse_leftbar']) ? 'upshrink.gif' : 'upshrink2.gif', '" alt="*" title="', $txt['upshrink_description'], '" style="margin: 2px 0;" border="0" /></a><img id="upshrinkTempLeftbar" src="', $settings['images_url'], '/blank.gif" alt="" style="margin-right: 0ex;" /></td>';
         if($context['TPortal']['rightbar'])
             echo '<td style="padding-left: 1ex;"><a href="javascript:void(0);" onclick="shrinkHeaderRightbar(!current_rightbar); return false;"><img id="upshrinkRightbar" src="', $settings['images_url'], '/', empty($options['collapse_rightbar']) ? 'upshrink.gif' : 'upshrink2.gif', '" alt="*" title="', $txt['upshrink_description'], '" style="margin: 2px 0;" border="0" /></a><img id="upshrinkTempRightbar" src="', $settings['images_url'], '/blank.gif" alt="" style="margin-right: 0ex;" /></td>';
// TinyPortal end
echo '


Oh, and the theme won't show up on the blog index, either.  If anyone can help me or point me in the right direction, I would really appreciate it.

Oh, yeah, www.happycurls.com is my site and I'm running OmegaOutline1.0.5 theme (working on it, anyway)
Title: Re: Hide panels custom help
Post by: IchBin on November 26, 2008, 03:39:43 AM
In tinyportal 1.x, the code that was used in TP 0.9.8 is no longer used. That is the code you posted. The code that calls the sidepanels is output by using the SMF layers system. You cannot simply remove the code like that to remove the sidepanels. You will have to do something like this if you want all the panels gone in your blogs. Inside your blogs.php or whatever its called in the Sources folder you'll need to add some code like this:


if (isset($_GET['blogs']))
tp_hidebars('all');


This may hide them in your blogs. But this is only if all your pages have blogs=id# on them. If blogs no longer exists in the URL you'll have to check for something else.

For future reference Please read the Posting Guidelines. (http://www.tinyportal.net/index.php/topic,581) This includes starting your own topic.
Title: Re: Hide panels custom help
Post by: atlantisrising on November 26, 2008, 02:34:10 PM
Oops!  I was actually in that thread, I'm not sure how this became a topic by itself, sorry!
Title: Re: Hide panels custom help
Post by: atlantisrising on November 26, 2008, 02:37:58 PM
Also, I couldn't find a manual install for TP on the SMF site so I went into the files that I had uploaded to my site, that's where I got that code from.  I'm not sure how that is the code for TP0.9.8 because I'm not using that version.
Title: Re: Hide panels custom help
Post by: G6Cad on November 26, 2008, 02:54:25 PM
If you use a theme thats made to work with TP v0978, that code will be included in the theme, allthough the theme will work with tp v1.0.6 aswell

And why are you looking at SMF for a documentation on TP when we have it here at this site thats made for support tp ?
Title: Re: Hide panels custom help
Post by: atlantisrising on November 26, 2008, 03:25:19 PM
That's where I downloaded TP so I just went back there for the manual install. 
Title: Re: Hide panels custom help
Post by: IchBin on November 26, 2008, 05:04:00 PM
Regardless where you got the code, that isn't what you're looking for.
Title: Re: Hide panels custom help
Post by: atlantisrising on November 26, 2008, 08:07:27 PM
Quote from: IchBinâ,,¢ on November 26, 2008, 05:04:00 PM
Regardless where you got the code, that isn't what you're looking for.

Understood.
Title: Re: Hide panels custom help
Post by: IchBin on November 27, 2008, 02:34:54 AM
Was my first post in this what you were looking for though?
Title: Re: Hide panels custom help
Post by: atlantisrising on November 27, 2008, 08:02:58 PM
Quote from: IchBinâ,,¢ on November 27, 2008, 02:34:54 AM
Was my first post in this what you were looking for though?

I'm not so good with coding so I'm going to show my friend what you recommended and see what happens.  I will be back with the outcome.  Thanks!
Title: Re: Hide panels custom help
Post by: atlantisrising on November 28, 2008, 01:18:52 PM
Just to let you know, I was going to uninstall blog community and reinstall when I found out that my TPBlockLayout. template didn't install correctly so I manually did it and now it works!  Thanks for the suggestions and time.