官术网_书友最值得收藏!

Custom fields – show related products on the product details page

We can achieve so many things by using the custom fields tab of the product we want to show related products of. But this is simpler than other custom fields recipes, in that we don't have to create a custom field first. Showing related products is often a good idea as it encourages customers to make more purchases.

Getting ready

Make sure you have created the products you want to use as related products.

How to do it...

We have created Joomla! the Movie and we will be making it a related product to the VirtueMart the Movie product. Here is how to do it:

  1. Select the Products links from the Products menu. Click on the product you want to add related products to. Now click on the Custom Fields tab of that product.
  2. Scroll down to the Related Products search box and begin typing the name of the product you want this product to relate to, as shown in the following screenshot:
  3. Click the product you want to add, click on Save, then search again and add any other products you want this one to relate to. Click on Save.

How it works...

If you go and visit the product details page, you will see that VirtueMart has created a custom field showing your related product(s), as shown in the following screenshot:

There's more...

You probably noticed while completing this recipe that you could use exactly the same process if you wanted the product to relate to a whole category of products. Just type your search and make your selections from the Related Categories section instead, as shown in the following screenshot:

主站蜘蛛池模板: 交城县| 吉水县| 三明市| 荣成市| 栾城县| 郧西县| 辽中县| 犍为县| 沂水县| 菏泽市| 新野县| 内江市| 柞水县| 锡林郭勒盟| 禹城市| 江孜县| 潞西市| 富平县| 山阳县| 项城市| 高青县| 郓城县| 长岭县| 石楼县| 邻水| 察雅县| 包头市| 楚雄市| 远安县| 忻州市| 比如县| 宁德市| 镇江市| 沙湾县| 沙雅县| 广宁县| 黎城县| 宜昌市| 静海县| 益阳市| 阳城县|