更新时间:2023-11-30 12:20:28
如果它用于新产品,而不用于特色产品(因为您必须对特色产品使用某些扩展名,而您未声明任何扩展名)
您需要更改\app\code\core\Mage\Catalog\Block\Product\New.php
If its for new products and not for featured products( as you will have to use some extension for featured products and you hav enot stated any)
You need to change the line in \app\code\core\Mage\Catalog\Block\Product\New.php
$products->setOrder(’news_from_date’)->setPageSize(5)->setCurPage(1);
更改为
$products->setOrder(’news_from_date’)->setPageSize(10)->setCurPage(1);
这只是参考代码.所以你需要创建模块,并覆盖块类
This is just a reference code. You should not change any core files so you need to create your module and override block class Mage_Catalog_Block_Product_New
在您的.phtml文件中将此代码用作第一行代码
Use this in your .phtml as first line of code
$this->setProductsCount(10);