Forked from mkdizajn/magento aw blog recent posts widget to display short content.php
Last active
August 29, 2015 14:07
-
-
Save Archie22is/e779506247572a435674 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* aheadWorks Co. | |
* | |
* NOTICE OF LICENSE | |
* | |
* This source file is subject to the EULA | |
* that is bundled with this package in the file LICENSE.txt. | |
* It is also available through the world-wide-web at this URL: | |
* http://ecommerce.aheadworks.com/AW-LICENSE.txt | |
* | |
* ================================================================= | |
* MAGENTO EDITION USAGE NOTICE | |
* ================================================================= | |
* This package designed for Magento community edition | |
* aheadWorks does not guarantee correct work of this extension | |
* on any other Magento edition except Magento community edition. | |
* aheadWorks does not provide extension support in case of | |
* incorrect edition usage. | |
* ================================================================= | |
* | |
* @category AW | |
* @package AW_Blog | |
* @version 1.2.1 | |
* @copyright Copyright (c) 2010-2012 aheadWorks Co. (http://www.aheadworks.com) | |
* @license http://ecommerce.aheadworks.com/AW-LICENSE.txt | |
*/ | |
?><?php if ($posts = $this->getRecent()): ?> | |
<div class="widget-latest"> | |
<h2><?php echo Mage::helper('blog')->__('Latest Posts'); ?></h2> | |
<ul> | |
<?php foreach ($posts as $post): ?> | |
<li><a href="<?php echo $post->getAddress(); ?>" ><?php echo $post->getTitle(); ?></a> | |
<div class="postContent"><?php echo $post->getShortContent(); //Mage::helper('core/string')->truncate(, 150); ?></div> | |
</li> | |
<?php endforeach; ?> | |
</ul> | |
</div> | |
<?php endif; ?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment