在woocommerce商店页面中重新排列标题,缩略图和价格的位置 [英] Reorder the position of title,thumbnail and price in woocommerce shop page

查看:75
本文介绍了在woocommerce商店页面中重新排列标题,缩略图和价格的位置的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在与wordpress woocommerce合作。我必须自定义网站的商店页面。我必须在其中将特色图片放在标题和价格下方。我为此尝试了一些尝试,但是对我却不起作用。

I am working with wordpress woocommerce. I have to customize the shop page of the website. In which I have to place the featured image below the title and price. I try few things for that but that not work for me.

我尝试更改如下所示的function.php文件中缩略图的优先级

I try to change the priority of thumbnail in function.php file like below

 remove_action( 'woocommerce_before_shop_loop_item_title', 'woocommerce_template_loop_product_thumbnail', 10 );    
add_action( 'woocommerce_before_shop_loop_item_title', 'woocommerce_template_loop_product_thumbnail', 90 );

这对我也不起作用,因为它实际上是商店页面上特色图像的两倍。有人可以告诉我如何在woocommerce中重新排序商店页面的缩略图,标题,价格吗?

This is also not works for me infact its double the featured image on shop page. Can anybody please tell me how can I reorder the shop page 's thumbnail,title, price in woocommerce?

推荐答案

让我们尝试一下

remove_action( 'woocommerce_after_shop_loop_item_title', 'woocommerce_template_loop_product_thumbnail', 10 );
add_action( 'woocommerce_before_shop_loop_item_title', 'woocommerce_template_loop_product_thumbnail', 90 );

这篇关于在woocommerce商店页面中重新排列标题,缩略图和价格的位置的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆