On 24 Sep 2006, at 22:24, Dave Crossland wrote:

> If you could provide it as a plugin, that would be awesome! :-)

Creating a plugin for a two-line patch for a totally trivial addition  
would be overkill, no?

Index: app/models/page_context.rb
===================================================================
--- app/models/page_context.rb  (revision 122)
+++ app/models/page_context.rb  (working copy)
@@ -40,6 +40,15 @@
      end

      #
+    # <r:if_children>...</r:if_children>
+    #
+    # Checks for existing children.
+    #
+    define_tag 'if_children' do |tag|
+      tag.expand if tag.locals.page.has_children?
+    end
+
+    #
      # <r:children:count />
      #
      # Renders the total number of children.


</Steven>
-- 
Steven Noels                            http://outerthought.org/
Outerthought                              Open Source Java & XML
stevenn at outerthought.org                stevenn at apache.org


_______________________________________________
Radiant mailing list
Post:   Radiant@lists.radiantcms.org
Search: http://radiantcms.org/mailing-list/search/
Site:   http://lists.radiantcms.org/mailman/listinfo/radiant

Reply via email to