|
Title: <solved> Hack is messing with template assigning Post by: Andrew on February 08, 2007, 07:58:34 PM I have a site with two templates.
The default template has 3 colunms and the assigned template has 1 I've assigned the single colunm template to the menu item which links to the SMF and that works ok .... BUT click on any link in the SMF and whammo the default 3 colunm template is what is used. I don't believe this is a SMF issue as I've used this concept with SMF where I didn't use a bridge. Using this bridge/hack makes it happen. What am I missing or what haven't I done which I should have? ============================ Version Information: Your Joomla version is: 1.0.12 Your SMF version is: 1.1.1 Your Joomla-SMF version: 2.0.2 Single database Single database Title: Re: Hack is messing with template assigning Post by: -Wolverine on February 08, 2007, 08:16:22 PM depending on when mosShowHead() is called in your joomla template, SMF's CSS may be loaded after your joomla template and conflicting CSS definitions get overwritten.
Title: Re: Hack is messing with template assigning Post by: Andrew on February 08, 2007, 08:40:21 PM Quote depending on when mosShowHead() is called in your joomla template, SMF's CSS may be loaded after your joomla template and conflicting CSS definitions get overwritten. Ok I can understand that ... • where should this go or is there a thread about this here? • conflicting css isn't the issue here I believe as the SMF template is workign ok, it's the wrapper which is causing the issue. The wrong template get's used when you click inside the SMF. -- edit clarity -- Thanks Title: Re: Hack is messing with template assigning Post by: -Wolverine on February 08, 2007, 09:00:56 PM the wrong template? Do you have the wrong template assigned to the forum link possibly? I'm trying to understand here.
Title: Re: Hack is messing with template assigning Post by: Andrew on February 09, 2007, 12:54:54 AM I'm not explaining this well eh? ;)
Template A ... is the default 3 colunm template applies to everything except the forum Template B ... is the single colunm template which is assigned to the SMF menu link. When I click on the link to SMF Template B is used. Which is correct. When I click on any link inside the SMF Tempalte A is used. Which is not correct. Trying to work out why it's reverting to the default (Template A) and not what's assigned. It's never happened before hence my query as to whetehr this is a bridge issue or SMF issue Title: Re: Hack is messing with template assigning Post by: -Wolverine on February 09, 2007, 07:41:15 AM and to be clear, these are Joomla templates, right? My guess is that the template engine isn't matching the url for whatever reason. My general method of handling this scenario is doing it using a file I call isPage.php. In this file I have methods like this:
Code: function isHomePage() { global $mosConfig_live_site; $req = mosGetParam($_SERVER, 'REQUEST_URI', ''); if (substr_count($mosConfig_live_site, '/') > 2 ) { $site = substr($mosConfig_live_site, strrpos($mosConfig_live_site, '/')).'/'; } else { $site = '/'; } if (strcasecmp($site, $req) == 0 || strcasecmp($site.'index.php', $req) == 0 || strcasecmp($site.'component/option,com_frontpage/Itemid,1/', $req) == 0 || strcasecmp($site.'index.php?option=com_frontpage&Itemid=1', $req) == 0) { return true; } return false; } This allows me to define a special subtemplate and still retain a single template for the site, with separate layouts. Does this sound like what you might need? I frequently use this to remove everything but the header and footer from a site that displays SMF. That way it is wrapped without the side modules, and gets full screen for display. Title: Re: Hack is messing with template assigning Post by: joomlanewbie on February 09, 2007, 08:32:14 AM there is a known issue with j.012 that affects how it generates content ids (which are menu items)
could this confuse the bridge? Title: Re: Hack is messing with template assigning Post by: -Wolverine on February 09, 2007, 04:43:14 PM its not the bridge that is failing here, as far as I can tell. Joomla templates use the itemid to determine which template to display, but every bridge URL contains the Itemid.
Title: Re: Hack is messing with template assigning Post by: Livebox on February 09, 2007, 05:13:26 PM • conflicting css isn't the issue here I believe as the SMF template is workign ok, it's the wrapper which is causing the issue. The wrong template get's used when you click inside the SMF. When you use the wrapper Mode both Css files ar loaded. The isseu is that the Joomla! and SMF template are using the same Class ID's so you have to fix that. Search this board for an example (posted this severall times) Great tool that can help you with this is the Webdeveloper Toolbar for Firefox. https://addons.mozilla.org/firefox/60/ Edit: also handy is to know how Css works. (specially when there are duplicate Class Id's) http://www.w3.org/Style/CSS/ Title: <solved> Re: Hack is messing with template assigning Post by: Andrew on February 10, 2007, 03:41:13 PM I'm beginning to think it actually is an itemid issue, as the whole look and feel of the site is perfect. Sorry Livebox :(
Here's what I have ... Menu link is .... index.php?option=com_smf&Itemid=80 Links inside the SMF are all ... index.php?option=com_smf&Itemid=78 There is no menu item with itemid 78 in any menu and none in the trash either. ----------- Solution ---------- I've left the post above so that others searching may see what's happened as what I'm about to say makes no sense otherwise. When I first made a menu link to the forum it had Itemid=78 and was in the the wrong menu. I removed that item id and trashed it. I created a new menu item now Itemid=80 I've been away for a day and I've discovered that the problem was actually cookies. Yes I've got cookies with Itemid=78 in them .... clean all the cookies and whammo it works!! Doh!! A trap so obvious when you think of it! <shaking head><red faced> Thanks to all for your time
Joomla Forum | Powered by SMF 1.1 RC1.
© 2001-2005, Lewis Media. All Rights Reserved. Joomla Bridge by JoomlaHacks.com |