# BEGIN sitemap.xml
<IfModule mod_rewrite.c>
RewriteRule ^(sitemap)\.xml$ $1.php
</IfModule>
# END sitemap.xml
你也可以在github的wordpress-sitemap.xml说明文件中看到使用步骤。
结束
如果你有什么疑问和好的想法,可以加入我们的QQ群讨论,或者在本页下面留言。
Warning: copy(): SSL operation failed with code 1. OpenSSL Error messages:
error:14090086:SSL routines:ssl3_get_server_certificate:certificate verify failed in /opt/lampp/htdocs/wordpresssummer/wp-content/themes/summerleaf/inc/summer_setting.php on line 546
Warning: copy(): Failed to enable crypto in /opt/lampp/htdocs/wordpresssummer/wp-content/themes/summerleaf/inc/summer_setting.php on line 546
Warning: copy(https://www.wordpressleaf.com/wp-content/themes/summerleaf/images/tx/33.png): failed to open stream: operation failed in /opt/lampp/htdocs/wordpresssummer/wp-content/themes/summerleaf/inc/summer_setting.php on line 546
Warning: copy(): SSL operation failed with code 1. OpenSSL Error messages:
error:14090086:SSL routines:ssl3_get_server_certificate:certificate verify failed in /opt/lampp/htdocs/wordpresssummer/wp-content/themes/summerleaf/inc/summer_setting.php on line 562
Warning: copy(): Failed to enable crypto in /opt/lampp/htdocs/wordpresssummer/wp-content/themes/summerleaf/inc/summer_setting.php on line 562
Warning: copy(https://www.wordpressleaf.com/wp-content/themes/summerleaf/images/tx/33.png): failed to open stream: operation failed in /opt/lampp/htdocs/wordpresssummer/wp-content/themes/summerleaf/inc/summer_setting.php on line 562
我弄的页面还是不对啊。搞不成和你一样的
先创建一个模板为SITEMAP的页面,页面无需填写任何内容,然后把页面放在菜单,至于页面的侧边栏,你在默认侧边栏上放置小工具就可以了,这个最简单呀。
至于这个sitemap.xml按照这篇的步骤设置就可以了,如果你不是APACHE的服务器,要自己来找一下你服务器的跳转代码。
为什么我照着这个办法,sitemap.php可以访问,xml死活访问不了呢,一直显示有点尴尬,该页无法显示?
提示什么?我记得原来群里有个网友也是这个问题,后来改了一下.htaccess的顺序就可以了。
nginx重写代码:
rewrite ^/sitemap.xml$ /sitemap.php last;
非常好。
阿里云虚拟主机.htaccess文件放那里啊?
一般放在网站的根目录。