VIP福利
主页 > 建站问题 > 织梦技巧 > dede单页制作Sitemap.xml地图

dede单页制作Sitemap.xml地图

刚发现站长平台有提交地图, 但dede就没有生成xml地图的功能, 所以自己用单页生成搞了个 具体操作为: 1.制作单页模板, 网址改成自己的, 和一般调用一样 ?xml version=1.0 encoding=UTF-8? urlset […]



刚发现站长平台有提交地图, 但dede就没有生成xml地图的功能, 所以自己用单页生成搞了个
具体操作为:
1.制作单页模板, 网址改成自己的, 和一般调用一样

 
<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
<url>
    <loc>http://www.dedesos.com/</loc>
<lastmod>{dede:arclist row=1 titlelen=24 orderby=pubdate}
[field:pubdate function=strftime('%Y-%m-%d',@me)/]
{/dede:arclist}</lastmod>
<changefreq>always</changefreq>
<priority>1.0</priority>
</url>
 
{dede:channel row='200' type='top'}
<url>
    <loc>https://www.dedesos.com[field:typelink /]</loc>
    <changefreq>always</changefreq>
    <priority>0.8</priority>
</url>
{/dede:channel}
 
{dede:channel type='son' typeid='指定栏目ID'}
<url>
<loc>https://www.dedesos.com[field:typelink /]</loc>
<changefreq>always</changefreq>
<priority>0.7</priority>
</url>
{/dede:channel}
 
{dede:arclist row='5000' orderby=pubdate}
<url>
    <loc>https://www.dedesos.com[field:arcurl/]</loc>
    <lastmod>[field:pubdate function=strftime('%Y-%m-%d',@me)/]</lastmod>
    <changefreq>always</changefreq>
    <priority>0.6</priority>
</url>
{/dede:arclist}
</urlset>


2. 在DEDE后台点击单独页面管理>>增加新页面


 


说点什么吧
  • 全部评论(0
    还没有评论,快来抢沙发吧!