mirror of
https://github.com/torrentpier/torrentpier
synced 2025-08-22 06:13:58 -07:00
feat: Bring back support seo_url
function in Sitemap.php
This commit is contained in:
parent
9a4d30c6da
commit
d4cbe77547
1 changed files with 10 additions and 2 deletions
|
@ -52,8 +52,12 @@ class Sitemap
|
||||||
");
|
");
|
||||||
|
|
||||||
while ($row = DB()->sql_fetchrow($sql)) {
|
while ($row = DB()->sql_fetchrow($sql)) {
|
||||||
|
$forum_url = FORUM_URL . $row['forum_id'];
|
||||||
|
if (function_exists('seo_url')) {
|
||||||
|
$forum_url = seo_url(FORUM_URL . $row['forum_id'], $row['forum_name']);
|
||||||
|
};
|
||||||
$forumUrls[] = [
|
$forumUrls[] = [
|
||||||
'url' => FORUM_URL . $row['forum_id'],
|
'url' => $forum_url,
|
||||||
'time' => $row['last_topic_time']
|
'time' => $row['last_topic_time']
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
@ -83,8 +87,12 @@ class Sitemap
|
||||||
$sql = DB()->sql_query("SELECT topic_id, topic_title, topic_last_post_time FROM " . BB_TOPICS . " " . $ignore_forum_sql . " ORDER BY topic_last_post_time ASC");
|
$sql = DB()->sql_query("SELECT topic_id, topic_title, topic_last_post_time FROM " . BB_TOPICS . " " . $ignore_forum_sql . " ORDER BY topic_last_post_time ASC");
|
||||||
|
|
||||||
while ($row = DB()->sql_fetchrow($sql)) {
|
while ($row = DB()->sql_fetchrow($sql)) {
|
||||||
|
$topic_url = TOPIC_URL . $row['topic_id'];
|
||||||
|
if (function_exists('seo_url')) {
|
||||||
|
$topic_url = seo_url(TOPIC_URL . $row['topic_id'], $row['topic_title']);
|
||||||
|
};
|
||||||
$topicUrls[] = [
|
$topicUrls[] = [
|
||||||
'url' => TOPIC_URL . $row['topic_id'],
|
'url' => $topic_url,
|
||||||
'time' => $row['topic_last_post_time'],
|
'time' => $row['topic_last_post_time'],
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue