Replace sitemap to the new external component.

This commit is contained in:
Yuriy Pikhtarev 2017-05-31 23:53:14 +03:00
commit 826bdea1f5
No known key found for this signature in database
GPG key ID: 3A9B5A757B48ECC6
17 changed files with 159 additions and 205 deletions

View file

@ -42,7 +42,7 @@ while (true) {
AND user_lastvisit = 0
AND user_session_time = 0
AND user_regdate <= " . (TIMENOW - 86400 * $not_activated_days) . "
AND user_id NOT IN(" . EXCLUDED_USERS_CSV . ")
AND user_id NOT IN(" . EXCLUDED_USERS . ")
LIMIT $users_per_cycle");
foreach ($sql as $row) {
@ -55,7 +55,7 @@ while (true) {
WHERE user_level = 0
AND user_posts = 0
AND user_lastvisit <= " . (TIMENOW - 86400 * $not_active_days) . "
AND user_id NOT IN(" . EXCLUDED_USERS_CSV . ")
AND user_id NOT IN(" . EXCLUDED_USERS . ")
LIMIT $users_per_cycle");
foreach ($sql as $row) {

View file

@ -28,13 +28,12 @@ if (!defined('BB_ROOT')) {
}
$map = new TorrentPier\Legacy\Sitemap();
$map->create();
$map->createSitemap();
if (@file_exists(BB_ROOT . "/sitemap/sitemap.xml")) {
$map_link = make_url('/sitemap/sitemap.xml');
if (file_exists(SITEMAP_DIR . '/sitemap.xml')) {
$map_link = make_url('sitemap/sitemap.xml');
$map->send_url("http://google.com/webmasters/sitemaps/ping?sitemap=", $map_link);
$map->send_url("http://ping.blogs.yandex.ru/ping?sitemap=", $map_link);
$map->send_url("http://www.bing.com/ping?sitemap=", $map_link);
$map->send_url("http://rpc.weblogs.com/pingSiteForm?name=InfraBlog&url=", $map_link);
$map->sendSitemap('http://google.com/webmasters/sitemaps/ping?sitemap=', $map_link);
$map->sendSitemap('http://ping.blogs.yandex.ru/ping?sitemap=', $map_link);
$map->sendSitemap('http://www.bing.com/ping?sitemap=', $map_link);
}

View file

@ -72,7 +72,7 @@ if ($bb_cfg['seed_bonus_enabled'] && $bb_cfg['seed_bonus_points'] && $bb_cfg['se
AND b.release_count <= $release
AND u.user_regdate < $user_regdate
AND u.user_active = 1
AND u.user_id not IN(" . EXCLUDED_USERS_CSV . ")
AND u.user_id not IN(" . EXCLUDED_USERS . ")
");
}