Compatibility with default template system

Tutorials for <a href="http://www.phpbbstyles.com/viewtopic.php?t=356">eXtreme Styles mod</a> for phpBB 2.0.

Moderator: Moderators

Compatibility with default template system

Postby PostBot on Wed Nov 26, 2003 11:56 am

How to write template compatible with both default template system and eXtreme Styles mod

Its simple - write correct code. If you write correct template code there will be no problems with eXtreme Styles mod.



To use eXtreme Styles mod features and keep template compatible with default template.php you can use one of these features:


1. eXtreme Styles mod switch.
There is root-level switch 'switch_xs_enabled' that you can use to write code that will be visible only with eXtreme Styles mod. Like this:
Code: Select all
<!-- BEGIN switch_xs_enabled -->
<?php
// this php code will be visible only if eXtreme Styles mod is enabled
?>
<!-- END switch_xs_enabled -->



2. Using replacement templates.
There is a feature to use different templates for default phpBB and phpBB with XS mod. To use that feature you need to create file xs.cfg in current template directory and write something like this:
Code: Select all
<?php
$replace['overall_header.tpl'] = 'overall_header_xs.tpl';
?>

After that when file overall_header.tpl is shown if forum uses default phpBB it will show overall_header.tpl and if forum uses eXtreme Styles mod it will show overall_header_xs.tpl


And of course you can use combination of those features using <!-- INCLUDE file.tpl --> to include default tpl file after you are done with processing tpl file for extreme styles mod. Look at jumpbox_xs.tpl in any of my themes for example.
Do NOT pm me, I don't visit this forum anymore, don't own it, don't provide any support and don't moderate.
User avatar
PostBot
Moderator
Moderator
 
Posts: 10659
Joined: Sat Aug 02, 2003 3:52 pm
Location: Mars

Postby bucky716 on Tue Jan 13, 2004 10:14 pm

If I'm installing a new template (helius 1.7) and have the eXtreme styles mod installed.. do I do all changes (hacks) to the overall_header.tpl file in the new template folder? or should they be done in a file overall_header_xs.tpl somewhere?
bucky716
Registered User
Registered User
 
Posts: 11
Joined: Sat Jan 10, 2004 3:33 am
Location: Buffalo, NY USA

Postby PostBot on Tue Jan 13, 2004 10:20 pm

you should edit files same way as it is described in mod installation. so if it sais edit overall_header.tpl then edit overall_header.tpl

hovewer, header code for Helius and subSilver are completely differet so it might be hard to modify it without knowing html. If you will have such problem then search for similar code instead of one that is written in mod installation instructions.
Do NOT pm me, I don't visit this forum anymore, don't own it, don't provide any support and don't moderate.
User avatar
PostBot
Moderator
Moderator
 
Posts: 10659
Joined: Sat Aug 02, 2003 3:52 pm
Location: Mars

Hello, I am slightly stuck...

Postby oimi on Sun Sep 19, 2004 4:14 pm

I tried to install the skin provided, called 'Aeolus'. I am slightly stuck, as now some of the features are missing. I thought I would try and install it and see what it looked like. Sadly, when I did this, I could not undo it, now I can't get access to the administration panel, and the forum is half operational, and half disfunctional. If you could help me out, I would be very grateful. Thank you, Shaun.

A comment which comes up when I click on administration panel is 'Template->make_filename(): Error - file does not exist', I guess this is the first step to making the forum functional again. But I am totally new to the realsm of skinning and styling forums. So if you could provide me with lots of description and details that would be great. :)

The forum in question is www.idst-home.com/idstforum/index.php
oimi
Registered User
Registered User
 
Posts: 2
Joined: Sun Sep 19, 2004 4:02 pm

Postby PostBot on Sun Sep 19, 2004 4:20 pm

You forgot to upload all subdirectories that are in style zip file.
Do NOT pm me, I don't visit this forum anymore, don't own it, don't provide any support and don't moderate.
User avatar
PostBot
Moderator
Moderator
 
Posts: 10659
Joined: Sat Aug 02, 2003 3:52 pm
Location: Mars

Postby oimi on Sun Sep 19, 2004 6:32 pm

So how do I do that?
Which directorie are these, and where do I put them?
oimi
Registered User
Registered User
 
Posts: 2
Joined: Sun Sep 19, 2004 4:02 pm


Return to eXtreme Styles mod tutorials

Who is online

Users browsing this forum: No registered users and 0 guests

cron