]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
Fix validation problem (unescaped ampersands) by making the program listing be CDATA.
authormyk%mozilla.org <>
Fri, 4 Apr 2008 11:47:44 +0000 (11:47 +0000)
committermyk%mozilla.org <>
Fri, 4 Apr 2008 11:47:44 +0000 (11:47 +0000)
docs/en/xml/customization.xml

index 1bc2b97eea9c451b95c1ac296094e34b88b96a8a..c85505c1f04fdfd30a1e9ca07750eb951e0d5b69 100644 (file)
       </para>
 
       <para>After untarring the localizations (or creating your own) in the 
-      <filename class="directory"><varname>BUGZILLA_ROOT</varname>/template</filename> directory,
+      <filename class="directory">BUGZILLA_ROOT/template</filename> directory,
       you must update the <option>languages</option> parameter to contain any
       localizations you'd like to permit. You may also wish to set the
       <option>defaultlanguage</option> parameter to something other than
       tool (e.g. <command>grep</command>) to search the standard templates
       for occurrences of <methodname>Hook.process</methodname> or browse
       the directory tree in
-      <filename><varname>BUGZILLA_ROOT</varname>/template/en/extension/hook/</filename>,
+      <filename>BUGZILLA_ROOT/template/en/extension/hook/</filename>,
       which contains a directory for each hook in the following location:
     </para>
 
     <para>
-      <filename><varname>BUGZILLA_ROOT</varname>/template/en/extension/hook/<varname>PATH_TO_STANDARD_TEMPLATE</varname>/<varname>STANDARD_TEMPLATE_NAME</varname>/<varname>HOOK_NAME</varname>/</filename>
+      <filename>BUGZILLA_ROOT/template/en/extension/hook/PATH_TO_STANDARD_TEMPLATE/STANDARD_TEMPLATE_NAME/HOOK_NAME/</filename>
     </para>
 
     <para>
       The Bugzilla reviewers will promptly review each hook request,
       name the hook, add it to the template, check the new version
       of the template into CVS, and create the corresponding directory in
-      <filename><varname>BUGZILLA_ROOT</varname>/template/en/extension/hook/</filename>.
+      <filename>BUGZILLA_ROOT/template/en/extension/hook/</filename>.
     </para>
 
     <para>
       <filename>useful-links.html.tmpl</filename>, which is located in
       the <filename>global/</filename> subdirectory on the standard Bugzilla 
       template path
-      <filename><varname>BUGZILLA_ROOT</varname>/template/en/default/</filename>.
+      <filename>BUGZILLA_ROOT/template/en/default/</filename>.
       Looking in <filename>useful-links.html.tmpl</filename>, you find
       the following hook at the end of the list of standard Bugzilla
       administration links:
 
     <para>
       The corresponding directory for this hook is
-      <filename><varname>BUGZILLA_ROOT</varname>/template/en/extension/hook/global/useful-links.html.tmpl/edit/</filename>.
+      <filename>BUGZILLA_ROOT/template/en/extension/hook/global/useful-links.html.tmpl/edit/</filename>.
     </para>
 
     <para>
         <para>
           You may want to prefix your extension template names
           with the name of your extension, e.g. 
-          <filename><literal>projman</literal>-foo.html.tmpl</filename>, 
+          <filename>projman-foo.html.tmpl</filename>, 
           so they do not conflict with the names of templates installed by
           other extensions.
         </para>
           If your extension includes entirely new templates in addition to
           extensions of standard templates, it should install those new
           templates into an extension-specific subdirectory of the
-          <filename><varname>BUGZILLA_ROOT</varname>/template/en/extension/</filename> 
+          <filename>BUGZILLA_ROOT/template/en/extension/</filename> 
           directory.  The <filename>extension/</filename> directory, like the 
           <filename>default/</filename> and <filename>custom/</filename>
           directories, is part of the template search path, so putting templates
         <para>
           Installation customizers can also take advantage of hooks when adding
           code to a Bugzilla template.  To do so, create directories in
-          <filename><varname>BUGZILLA_ROOT</varname>/template/en/custom/hook/</filename>
+          <filename>BUGZILLA_ROOT/template/en/custom/hook/</filename>
           equivalent to the directories in
-          <filename><varname>BUGZILLA_ROOT</varname>/template/en/extension/hook/</filename>          
+          <filename>BUGZILLA_ROOT/template/en/extension/hook/</filename>          
           for the hooks you want to use, then place your customization templates
           into those directories.
         </para>
     }</programlisting>
       This says that only users in the group "quality_assurance" can change
       the QA Contact field of a bug. Getting more weird:
-      <programlisting>    if (($field eq "priority") &&
+      <programlisting><![CDATA[    if (($field eq "priority") &&
         (Bugzilla->user->email =~ /.*\@example\.com$/))
     {
         if ($oldvalue eq "P1") {
         else {
             return 0;
         }
-    }</programlisting>
+    }]]></programlisting>
       This says that if the user is trying to change the priority field,
       and their email address is @example.com, they can only do so if the
       old value of the field was "P1". Not very useful, but illustrative.