A rather controversial new entry to the FAQ. See bug 107917. I

decided one way for the Guide, based upon the code I see currently
checked in.  If I'm wrong, feel free to correct it!


git-svn-id: svn://10.0.0.236/trunk@132989 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
mbarnson%sisna.com
2002-11-05 03:09:15 +00:00
parent c05bb2bd12
commit 746c96cc02
2 changed files with 70 additions and 0 deletions

View File

@@ -1131,6 +1131,41 @@
<qandadiv id="faq-hacking">
<title>Bugzilla Hacking</title>
<qandaentry>
<question>
<para>
What kind of style should I use for templatization?
</para>
</question>
<answer>
<para>
Gerv and Myk suggest a 2-space endent, with embedded code sections on
their own line, in line with outer tags. Like this:</para>
<programlisting><![CDATA[
<fred>
[% IF foo %]
<bar>
[% FOREACH x = barney %]
<tr>
<td>
[% x %]
</td>
<tr>
[% END %]
[% END %]
</fred>
]]></programlisting>
<para> Myk also recommends you turn on PRE_CHOMP in the template
initialization to prevent bloating of HTML with unnecessary whitespace.
</para>
<para>Please note that many have differing opinions on this subject,
and the existing templates in Bugzilla espouse both this and a 4-space
style. Either is acceptable; the above is preferred.</para>
</answer>
</qandaentry>
<qandaentry>
<question>
<para>

View File

@@ -1131,6 +1131,41 @@
<qandadiv id="faq-hacking">
<title>Bugzilla Hacking</title>
<qandaentry>
<question>
<para>
What kind of style should I use for templatization?
</para>
</question>
<answer>
<para>
Gerv and Myk suggest a 2-space endent, with embedded code sections on
their own line, in line with outer tags. Like this:</para>
<programlisting><![CDATA[
<fred>
[% IF foo %]
<bar>
[% FOREACH x = barney %]
<tr>
<td>
[% x %]
</td>
<tr>
[% END %]
[% END %]
</fred>
]]></programlisting>
<para> Myk also recommends you turn on PRE_CHOMP in the template
initialization to prevent bloating of HTML with unnecessary whitespace.
</para>
<para>Please note that many have differing opinions on this subject,
and the existing templates in Bugzilla espouse both this and a 4-space
style. Either is acceptable; the above is preferred.</para>
</answer>
</qandaentry>
<qandaentry>
<question>
<para>