aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB
diff options
context:
space:
mode:
authorHenry Sudhof <kellanved@phpbb.com>2008-07-30 11:45:44 +0000
committerHenry Sudhof <kellanved@phpbb.com>2008-07-30 11:45:44 +0000
commitb6d3eff8c8ae6888364c287afc0d2fc1d2079017 (patch)
treecb3753a5b0e0749a4f5ccad4b2ca63cbcb864f4e /phpBB
parentb3cff3489012d0ac17348c70986e0dd8d96d80c9 (diff)
downloadforums-b6d3eff8c8ae6888364c287afc0d2fc1d2079017.tar
forums-b6d3eff8c8ae6888364c287afc0d2fc1d2079017.tar.gz
forums-b6d3eff8c8ae6888364c287afc0d2fc1d2079017.tar.bz2
forums-b6d3eff8c8ae6888364c287afc0d2fc1d2079017.tar.xz
forums-b6d3eff8c8ae6888364c287afc0d2fc1d2079017.zip
updated to mention template changes
git-svn-id: file:///svn/phpbb/branches/phpBB-3_0_0@8732 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB')
-rw-r--r--phpBB/docs/coding-guidelines.html51
1 files changed, 47 insertions, 4 deletions
diff --git a/phpBB/docs/coding-guidelines.html b/phpBB/docs/coding-guidelines.html
index 1e7faf88e5..2f333756d0 100644
--- a/phpBB/docs/coding-guidelines.html
+++ b/phpBB/docs/coding-guidelines.html
@@ -69,7 +69,15 @@
</ol>
</li>
<li><a href="#styling">Styling</a></li>
- <li><a href="#templating">Templating</a></li>
+ <ol style="list-style-type: lower-roman;">
+ <li><a href="#cfgfiles">Style Config Files</a></li>
+ <li><a href="#genstyling">General Styling Rules</a></li>
+ </ol></li>
+ <li><a href="#templating">Templating</a>
+ <ol style="list-style-type: lower-roman;">
+ <li><a href="#templates">General Templating</a></li>
+ <li><a href="#fallbacks">Template Fallbacks</a></li>
+ </ol></li>
<li><a href="#charsets">Character Sets and Encodings</a></li>
<li><a href="#translation">Translation (<abbr title="Internationalisation">i18n</abbr>/<abbr title="Localisation">L10n</abbr>) Guidelines</a>
<ol style="list-style-type: lower-roman;">
@@ -995,8 +1003,15 @@ append_sid(&quot;{$phpbb_root_path}memberlist.$phpEx&quot;, 'mode=group&amp;amp;
<div class="inner"><span class="corners-top"><span></span></span>
<div class="content">
-
-<h4>General things</h4>
+ <a name="cfgfiles"></a><h3>3.i. Style Config Files</h3>
+ <p>Style cfg files are simple name-value lists with the information necessary for installing a style. Similar cfg files exist for templates, themes and imagesets. These follow the same principle and will not be introduced individually. The important part of the style configuration file is assigning an unique name.</p>
+ <div class="codebox"><pre>
+# General Information about this style
+name = prosilver
+copyright = &copy; phpBB Group, 2007
+version = 3.0.2
+ </pre></div>
+ <a name="genstyling"></a><h3>3.2. General Styling Rules</h3>
<p>Templates should be produced in a consistent manner. Where appropriate they should be based off an existing copy, e.g. index, viewforum or viewtopic (the combination of which implement a range of conditional and variable forms). Please also note that the intendation and coding guidelines also apply to templates where possible.</p>
<p>The outer table class <code>forumline</code> has gone and is replaced with <code>tablebg</code>.</p>
@@ -1063,7 +1078,8 @@ append_sid(&quot;{$phpbb_root_path}memberlist.$phpEx&quot;, 'mode=group&amp;amp;
<div class="inner"><span class="corners-top"><span></span></span>
<div class="content">
-
+ <a name="templates"></a><h3>4.i. General Templating</h3>
+
<h4>File naming</h4>
<p>Firstly templates now take the suffix &quot;.html&quot; rather than &quot;.tpl&quot;. This was done simply to make the lifes of some people easier wrt syntax highlighting, etc.</p>
@@ -1451,6 +1467,25 @@ div
&lt;/fieldset&gt
&lt;/form&gt
</pre></div><br />
+
+ <a name="fallbacks"></a><h3>4.ii. Template Fallbacks</h3>
+ <p>When basing a new template on an existing one, it is not necessary to provide all template files. By declaring the template to be &quot;<strong>inheriting</strong>&quot; in the template configuration file.</p>
+ <p>The Limitation on this is that the base style has to installed and complete, meaning that it is not itself using a fallback.</p>
+ <p>The effect of doing so is that the template engine will use the files in the new template where they exist, but fall back to files in the base template otherwise. Declaring a style to be inheriting also causes it to use some of the configuration settings of the base style, notably database storage.</p>
+ <p>We strongly encourage the use of fallbacks for styles based on the bundled styles, as it will ease the update procedure.</p>
+ <div class="codebox"><pre>
+ # General Information about this template
+ name = inherits
+ copyright = &copy; phpBB Group, 2007
+ version = 3.0.2
+
+ # Defining a different template bitfield
+ template_bitfield = lNg=
+
+ # Are we inheriting?
+ inherit_from = prosilver
+ </pre></div>
+
</div>
<div class="back2top"><a href="#wrap" class="top">Back to Top</a></div>
@@ -2217,6 +2252,14 @@ if (utf8_case_fold_nfc($string1) == utf8_case_fold_nfc($string2))
<div class="content">
+
+<h3>Revision 8732</h3>
+
+<ul>
+ <li>Added cfg files.</li>
+ <li>Added template <a href="#fallbacks">fallbacks</a>.</li>
+</ul>
+
<h3>Revision 8596+</h3>
<ul>