简体   繁体   English

尝试覆盖Woocommerce我的帐户页面模板

[英]Trying to override Woocommerce My Account page template

Essentially, I want to remove the registration form on the My Account page. 本质上,我想删除“我的帐户”页面上的注册表格。 I tried setting up the file structure in my Theme folder and everything looks correct. 我尝试在主题文件夹中设置文件结构,并且一切看起来正确。 But when I try to make changes to the template nothing happens. 但是,当我尝试对模板进行更改时,什么也没有发生。

my-child-theme/woocommerce/myaccount/form-login.php 我的孩子主题/woocommerce/myaccount/form-login.php

This is how I have it setup. 这就是我的设置方法。 Woocommerce detects the override in system status too. Woocommerce也检测到系统状态中的替代。 I tried adding a class to the register form so that I could hide the form using css but it doesn't appear in the code. 我尝试将一个类添加到注册表单,以便可以使用css隐藏该表单,但它不会出现在代码中。

Any clues as to what I'm missing? 关于我所缺少的任何线索吗?

Thanks 谢谢

尝试清除缓存,在wp-config文件中定义false缓存。

Hello Have you tried to put it in main theme with the same structure?? 您好,您是否尝试过将其以相同的结构放在主主题中? Or is there any woo commerce folder exists in your main theme. 或主主题中是否存在任何woo Commerce文件夹。

Use this CSS in your style.css - 在您的style.css中使用此CSS-

.entry-content #my-courses .col-2
     {
       display : none;
     }

hope this will help you. 希望这会帮助你。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM