svn: /pear2/sandbox/SimpleChannelFrontend/trunk/www/templates/ Categories.tpl.php

From: Date: Thu, 19 Nov 2009 15:25:03 +0000
Subject: svn: /pear2/sandbox/SimpleChannelFrontend/trunk/www/templates/ Categories.tpl.php
Groups: php.pear.cvs php.pear.core 
Request: Send a blank email to pear-core+get-9037@lists.php.net to get a copy of this message
saltybeagle Thu, 19 Nov 2009 15:25:03 +0000 Revision: http://svn.php.net/viewvc?view=revision&revision=291006 Log: Use an unordered list to list all packages in a category. Changed paths: U pear2/sandbox/SimpleChannelFrontend/trunk/www/templates/Categories.tpl.php Modified: pear2/sandbox/SimpleChannelFrontend/trunk/www/templates/Categories.tpl.php =================================================================== --- pear2/sandbox/SimpleChannelFrontend/trunk/www/templates/Categories.tpl.php 2009-11-19 15:24:39 UTC (rev 291005) +++ pear2/sandbox/SimpleChannelFrontend/trunk/www/templates/Categories.tpl.php 2009-11-19 15:25:03 UTC (rev 291006) @@ -11,8 +11,16 @@ <?php foreach ($context->categories as $category) : ?> <li id="category-1" class="category category-clear"> - <h3><a href=""><span class="category-title"><?php echo $category->name; ?></span> <span class="category-count"><?php echo count($category);?></span></a></h3> - <div><?php foreach ($category as $package) echo '<a href="./?view=package&amp;package='.$package->name.'">'.$package->name.'</a>'; ?></div> + <h3><a href=""><span class="category-title"><?php echo $category->name; ?></span> <span class="category-count"><?php echo count($category); ?></span></a></h3> + <div><?php + if (count($category)) { + echo '<ul>'; + foreach ($category as $package) { + echo '<li><a href="./?view=package&amp;package='.$package->name.'">'.$package->name.'</a></li>'; + } + echo '</ul>'; + } + ?></div> </li> <?php endforeach; ?>

« previous php.pear.core (#9037) next »