mirror of
https://gitee.com/ulthon/ulthon_information.git
synced 2026-03-03 16:24:28 +08:00
优化站点地图和动态样式;
This commit is contained in:
@@ -26,9 +26,9 @@ class Sitemap
|
||||
|
||||
$urlset_page_post->add($index_url);
|
||||
|
||||
$list_post = Post::cache(60)->where('status',1)->select();
|
||||
$list_post = Post::cache(60)->where('status', 1)->whereIn('tpl_name', [''])->select();
|
||||
|
||||
foreach ($list_post as $model_post){
|
||||
foreach ($list_post as $model_post) {
|
||||
$url_post = new Url($model_post->read_url);
|
||||
$url_post->setChangeFreq('yearly');
|
||||
|
||||
@@ -39,7 +39,6 @@ class Sitemap
|
||||
$url_post->setPriority(0.9);
|
||||
|
||||
$urlset_page_post->add($url_post);
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -49,7 +48,5 @@ class Sitemap
|
||||
$urlset_page_post->accept($dirver);
|
||||
|
||||
return $dirver->output();
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user