Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
 Multiple Template Prefixes
RocketFoot Offline
Senior Member
****
Posts: 338
Joined: Jul 2010
Post: #1
Multiple Template Prefixes
I have a slight issue with 3 forums that I used template prefixes to alter the forumbit_depth2 templates...but I have run into a layout problem with the GoMobile theme.  The forums are messing up the mobile theme's margins.

Is there a way to make a theme use the default forumbit_depth2 temp or is there a way to collapse/hide the forum just on the mobile theme?

[Image: gallery_2_628_39582.jpg]
02-11-2011 02:36 AM
Find all posts by this user Quote this message in a reply
RateU Offline
Administrator
*******
Posts: 2,350
Joined: Mar 2010
Post: #2
RE: Multiple Template Prefixes
I'm sorry, but I can't fully understand what you mean?

02-11-2011 02:59 AM
Find all posts by this user Quote this message in a reply
RocketFoot Offline
Senior Member
****
Posts: 338
Joined: Jul 2010
Post: #3
RE: Multiple Template Prefixes
I have a new theme that needs to use a different forumbit_depth2_forum template other than the global one we created for the default theme...

How can I specify a certain theme to use a certain template?  I still want to keep the custom template active in my default theme.

See screen caps...mobile theme is not pulling the right forum icons as well as layout issues with the banners...

I think what I need to do is edit the mobile theme to point to a different forumbit_depth2_forum template but where to edit this at?  i could create a new template and call it mobile_forumbit_depth2_forum or something like that.  I just don't know how to do such a thing.


Attached File(s) Thumbnail(s)
       

[Image: gallery_2_628_39582.jpg]
(This post was last modified: 02-11-2011 03:23 AM by RocketFoot.)
02-11-2011 03:15 AM
Find all posts by this user Quote this message in a reply
RateU Offline
Administrator
*******
Posts: 2,350
Joined: Mar 2010
Post: #4
RE: Multiple Template Prefixes
What is template prefix for the three forum?

(This post was last modified: 02-11-2011 03:39 AM by RateU.)
02-11-2011 03:39 AM
Find all posts by this user Quote this message in a reply
RocketFoot Offline
Senior Member
****
Posts: 338
Joined: Jul 2010
Post: #5
RE: Multiple Template Prefixes
(02-11-2011 03:39 AM)RateU Wrote:  What is template prefix for the three forum?
Those 3 forums use: mp_


Now, this code is for the toned down version that the gomobile theme needs:

Code:
1
2
3
4
5
6
7
8
9
<tr>
	<td class="{$bgcolor}" align="center" valign="middle" width="1"><img src="{$theme['imgdir']}/{$lightbulb['folder']}.gif" alt="{$lightbulb['altonoff']}" title="{$lightbulb['altonoff']}" width="16" height="16" class="ajax_mark_read" id="mark_read_{$forum['fid']}" /></td>
	<td class="{$bgcolor}" valign="middle" onclick="location.href='{$forum_url}';">
		<strong><a href="{$forum_url}">{$forum['name']}</a></strong>
		<div class="lastbytext">{$posts}{$unapproved['unapproved_posts']} {$lang->forumbit_posts}. {$lang->gomobile_lastpost} {$lastpost_date}</div>
	</td>
	<td class="{$bgcolor}" valign="middle" width="1" align="right">{$lastpost}</td>
</tr>
{$subforums}


[Image: gallery_2_628_39582.jpg]
(This post was last modified: 02-11-2011 03:44 AM by RocketFoot.)
02-11-2011 03:42 AM
Find all posts by this user Quote this message in a reply
RateU Offline
Administrator
*******
Posts: 2,350
Joined: Mar 2010
Post: #6
RE: Multiple Template Prefixes
Try this way:
Create a new mp_forumbit_depth2_forum template directly in your mobile theme (not in global templates). Copy the entire original forumbit_depth2_forum code from your mobile theme into this new template. So, you will have two mp_forumbit_depth2_forum template. One in Global template, and the other in your mobile template.

02-11-2011 03:51 AM
Find all posts by this user Quote this message in a reply
RocketFoot Offline
Senior Member
****
Posts: 338
Joined: Jul 2010
Post: #7
RE: Multiple Template Prefixes
RateU...you are a MyBb Genius!  That worked like a charm!  I was going crazy trying to think of a solution but you make it look easy!

[Image: gallery_2_628_39582.jpg]
(This post was last modified: 02-11-2011 04:02 AM by RocketFoot.)
02-11-2011 04:02 AM
Find all posts by this user Quote this message in a reply
RateU Offline
Administrator
*******
Posts: 2,350
Joined: Mar 2010
Post: #8
RE: Multiple Template Prefixes
Actually, Yumi has taught us about theme priority in MyBB/XThreads somewhere here at MyBB Hacks. I will try to find the post, so we can learn each other.

EDIT:
Here is the post:
http://mybbhacks.zingaburga.com/showthre...http://mybbhacks.zingaburga.com/showthread.php?tid=288&pid=31

(This post was last modified: 02-11-2011 05:49 AM by RateU.)
02-11-2011 05:35 AM
Find all posts by this user Quote this message in a reply
RocketFoot Offline
Senior Member
****
Posts: 338
Joined: Jul 2010
Post: #9
RE: Multiple Template Prefixes
Thanks!  I am amazed daily by the power of XThreads!

[Image: gallery_2_628_39582.jpg]
02-11-2011 10:13 AM
Find all posts by this user Quote this message in a reply

« Next Oldest | Next Newest »

 Standard Tools
Forum Jump: