Ecshop Home Call item under a category |assign_cat_goods ()

Source: Internet
Author: User

Ecshop Home Call category under the product is actually very simple, there are template settings there can be set up, but that can only be used cat_goods.lib, inconvenient, so I want to see how can be simple implementation of Ecshop home call category under the product

Only need to write in index.php such a sentence: Assign_cat_goods (20,10);

Where 20 is the number of categories id,10 is called

Assign_cat_goods This function is inside the includes/lib_goods.php.

And then there's the Ecshop template that calls the product.

<!–{foreach from= $cat _goods_20 item=goods}–>
<divclass= "Cat_box" >
<div class= "img" ><ahref= "{$goods. URL}" target= "_blank" ></a></div>
<div class= "name" ><ahref= "{$goods. URL}" target= "_blank" >{$goods. Short_name|escape:html|truncate:10} </a><br/>
<span class= "Fontr fontbfontbig" >{$goods .shop_price}</span></div>
</div>
<!–{/foreach}–>

The variable called by Ecshop is $cat_goods_20, where 20 is the category ID

Ecshop Home Call item under a category |assign_cat_goods ()

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.