Php woocommerce-更改类别中产品的html
产品的html如下所示:Php woocommerce-更改类别中产品的html,php,wordpress,woocommerce,Php,Wordpress,Woocommerce,产品的html如下所示: <li class="post-13 product type-product status-publish has-post-thumbnail first taxable shipping-taxable purchasable product-type-simple product-cat-printer instock"> <a href="http://xxx"> <img width="150" heig
<li class="post-13 product type-product status-publish has-post-thumbnail first taxable shipping-taxable purchasable product-type-simple product-cat-printer instock">
<a href="http://xxx">
<img width="150" height="150" src="http://xx" class="attachment-shop_catalog wp-post-image" alt="" />
<h3>abc</h3>
<span class="price"><span class="amount">15.86 €</span></span>
</a>
<div class="gridlist-buttonwrap">
<a href="xx?add-to-cart=13" rel="nofollow" data-product_id="13" data-product_sku="" class="button add_to_cart_button product_type_simple">Buy</a>
</div>
<hr />
</li>
可以把价格移到按钮旁边吗
<li class="post-13 product type-product status-publish has-post-thumbnail first taxable shipping-taxable purchasable product-type-simple product-cat-printer instock">
<a href="http://xxx">
<img width="150" height="150" src="http://xx" class="attachment-shop_catalog wp-post-image" alt="" />
<h3>abc</h3>
</a>
<div class="abc">
<a href="xx?add-to-cart=13" rel="nofollow" data-product_id="13" data-product_sku="" class="button add_to_cart_button product_type_simple">Buy</a>
<span class="price"><span class="amount">15.86 €</span></span>
</div>
</li>
15.86欧元;
我发现的唯一方法是编辑插件的核心,这是没有用的,因为我会在更新后丢失所有更改
编辑:例如,它们具有以下结构:
<li>
<a href="http://demo2.woothemes.com/sliding/shop/yellow-necklace/" style="width: 192px; height: 295px;">
<img width="192" height="295" src="http://demo2.woothemes.com/sliding/files/2011/11/yellow-necklace-192x295.jpg" class="attachment-woo_sliding_slider wp-post-image" alt="yellow-necklace" />
<div class="meta">
<h3>Yellow Necklace</h3>
<span class="slider-price"><span class="amount">£19.00</span></span>
</div>
</a>
</li>
您可以覆盖模板文件,并且在更新woocommerce时不会更新该模板文件
来自吴哥商业
或者,您可以通过以下方式以升级安全的方式编辑这些文件:
覆盖。只需将其复制到名为
/woocommerce,保持相同的文件结构
示例:要覆盖管理订单通知,请复制:
woocommerce/templates/email/admin-new-order.php发送至
yourtheme/woocommerce/emails/admin-new-order.php
是的,我知道,但是我还没有找到任何可以编辑的模板文件。你找到解决方案了吗?这里也有同样的问题。