首页 » SEO优化 » php虚拟refer技巧_优化WordPress网站robots协议并经由进程Rank Math添加治理

php虚拟refer技巧_优化WordPress网站robots协议并经由进程Rank Math添加治理

访客 2024-12-06 0

扫一扫用手机浏览

文章目录 [+]

User-agent: Disallow: /wp-admin/Disallow: /wp-includes/Allow: /wp-admin/admin-ajax.php2.优化后的robots协议

以下是网上各位大神总结优化后的robots协议,可以直接添加利用。
个中赤色部分要修正为你网站的sitemap地址。

User-agent: Allow: /wp-content/uploads/Allow: /.html$Allow: /.png$Allow: /.jpg$Allow: /.jepg$Allow: /.gif$Allow: /.bmp$Disallow: /wp-admin/Disallow: /wp-login.phpDisallow: /wp-includes/Disallow: /wp-content/pluginsDisallow: /wp-content/themesDisallow: /wp-config-sample.phpDisallow: /refer/Disallow: /search/Disallow: /trackback/Disallow: /comments/Disallow: /attachment/Disallow: /comments/feedDisallow: /feedDisallow: //feedDisallow: //comment-page-Disallow: /?replytocom=Disallow: //trackbackDisallow: /?s=Disallow: //?s=\Disallow: /wp-.phpDisallow: /go.php?url=Sitemap:https://yourdomain.com/sitemap_index.xmlSitemap:https://yourdomain.com/post-sitemap.xmlSitemap:https://yourdomain.com/page-sitemap.xmlSitemap:https://yourdomain.com/product-sitemap.xmlSitemap:https://yourdomain.com/category-sitemap.xml3.Rank Math添加设置robots协议

登录WordPress网站后台》点击Rank Math》General Settings》Edit robots.txt

php虚拟refer技巧_优化WordPress网站robots协议并经由进程Rank Math添加治理

在设置窗口直接复制粘贴上面优化的robots协议,sitemap地址记得改成你自己的网站舆图

php虚拟refer技巧_优化WordPress网站robots协议并经由进程Rank Math添加治理
(图片来自网络侵删)

末了点击【Save changes】即可

4.查看网站robots协议

在浏览器窗口输入https://yourdomain.com/robots.text即可以看到网站的robots协议

末了总结

网站robots协议对付我们网站SEO优化还是非常主要的,值得重视,特殊是很多新手站长每每忽略这个文件。
如果你没有安装Rank Math这款SEO插件,也可以自己创建一个robots.txt的文件,粘贴好上面的robots协议规则,然后上传到网站根目录即可。
当然其他类似的SEO插件,比如Yoast SEO插件基本也供应robots管理功能。
方法是一样的。

优化WordPress网站robots协议,并通过Rank Math添加管理 - 自由超

相关文章