admin管理员组文章数量:1287230
I'm trying to remove the author pages as well as the links to the author pages on my wordpress website powered by Divi.
First, I disabled author archives and pages with the Yoast plugin.
Then, I used a short CSS snippet to disable the mouse pointer. It's working correctly, but the balise was still existing. Meaning, the search engine bots were getting a 301 redirect when requesting the document.
So, I asked some guys on a Divi forum and they provided me the following snippet
<script>
jQuery(function($){
$(".author a").attr("href", "#");
});
</script>
So, I added it. Nevertheless, there was still a link looping on the same page. If I can see it in the source code, the googlebot can too.
And I don't want it to waste its ressources on looping on the same page.
So, then I tried this snippet:
<script>
jQuery(function($){
$(".author a").removeAttr("href");
});
</script>
While in the source code it seems "ok", when I crawl the website with Screaming Frog, it still finds many /author/ pages. But when I explore the source code of the "origin" pages, I don't find any link containing /author/ or the author name... (I flushed out the cache already)
I've been spending hours on this topic already. I'm open to any idea.
Cheers!
I'm trying to remove the author pages as well as the links to the author pages on my wordpress website powered by Divi.
First, I disabled author archives and pages with the Yoast plugin.
Then, I used a short CSS snippet to disable the mouse pointer. It's working correctly, but the balise was still existing. Meaning, the search engine bots were getting a 301 redirect when requesting the document.
So, I asked some guys on a Divi forum and they provided me the following snippet
<script>
jQuery(function($){
$(".author a").attr("href", "#");
});
</script>
So, I added it. Nevertheless, there was still a link looping on the same page. If I can see it in the source code, the googlebot can too.
And I don't want it to waste its ressources on looping on the same page.
So, then I tried this snippet:
<script>
jQuery(function($){
$(".author a").removeAttr("href");
});
</script>
While in the source code it seems "ok", when I crawl the website with Screaming Frog, it still finds many /author/ pages. But when I explore the source code of the "origin" pages, I don't find any link containing /author/ or the author name... (I flushed out the cache already)
I've been spending hours on this topic already. I'm open to any idea.
Cheers!
Share Improve this question asked Sep 20, 2021 at 20:00 Quentin H.Quentin H. 11 bronze badge1 Answer
Reset to default 0If you want to remove in your wordpress website powered by Divi. then you can flow this some steps. 1.login your Dashboard. 2.Go to Appearance. 3.Then go to Theme Editor Or Editor. 4.There will a css code . 5.Paste this code
.site-info { display: none; }
本文标签: phpRemove Author Links
版权声明:本文标题:php - Remove Author Links 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1741307263a2371442.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论