[MKDoc-commit] [1.6] factor out comments loop as a fragment

bruno at mkdoc.demon.co.uk bruno at mkdoc.demon.co.uk
Wed Aug 24 10:51:42 BST 2005


Log Message:
-----------
[1.6] factor out comments loop as a fragment

Tags:
----
mkdoc-1-6

Modified Files:
--------------
    mkd/templates/document/default:
        en.html

Added Files:
-----------
    mkd/templates/fragments/comments:
        en.html

-------------- next part --------------
Index: en.html
===================================================================
RCS file: /var/spool/cvs/mkd/templates/document/default/Attic/en.html,v
retrieving revision 1.6.2.54
retrieving revision 1.6.2.55
diff -Ltemplates/document/default/en.html -Ltemplates/document/default/en.html -u -r1.6.2.54 -r1.6.2.55
--- templates/document/default/en.html
+++ templates/document/default/en.html
@@ -96,26 +96,7 @@
           </div>
         </div>
 
-        <div
-          class="comments"
-          petal:condition="true: Comment_Loop"
-        >
-        <h2>Comments</h2>
-        <div 
-          petal:repeat="component Comment_Loop"
-          petal:omit-tag=""
-        >
-          <div 
-            petal:replace="structure component/as_xhtml"
-          >
-            Comments Go Here
-          </div>
-        </div>
-        </div>
-        <p
-          class="add-a-comment"
-          petal:condition="true: comment/would_activate"
-        >You may <a petal:attributes="href comment/uri" href="../../comment/en.html">add a comment</a> to this document.</p>
+        <?include file="/fragments/comments/"?>
       </div>
 
       <!--? This is the next and previous menu. ?-->
--- /dev/null
+++ templates/fragments/comments/en.html
@@ -0,0 +1,26 @@
+<!--?
+
+This template is used for rendering a list of comments in documents. 
+
+?-->
+
+        <div
+          class="comments"
+          petal:condition="true: Comment_Loop"
+        >
+        <h2>Comments</h2>
+        <div 
+          petal:repeat="component Comment_Loop"
+          petal:omit-tag=""
+        >
+          <div 
+            petal:replace="structure component/as_xhtml"
+          >
+            Comments Go Here
+          </div>
+        </div>
+        </div>
+        <p
+          class="add-a-comment"
+          petal:condition="true: comment/would_activate"
+        >You may <a petal:attributes="href comment/uri" href="../../comment/en.html">add a comment</a> to this document.</p>


More information about the MKDoc-commit mailing list