3namespace Bitrix\Seo\Sitemap\Source;
5use Bitrix\Main\SiteTable;
6use Bitrix\Seo\Sitemap\File;
7use Bitrix\Seo\Sitemap\Internals\IblockTable;
8use Bitrix\Seo\RobotsFile;
9use Bitrix\Seo\Sitemap\Internals\SitemapTable;
10use Bitrix\Seo\Sitemap\Job;
58 $iblocksForSitemap = IblockTable::query()
59 ->setSelect([
'SITEMAP_ID'])
64 foreach ($iblocksForSitemap as
$iblock)
80 $url = str_replace([
'http://',
'https://'],
'',
$url);
83 if (mb_substr(
$url, 0, mb_strlen(
'#SERVER_NAME#')) ==
'#SERVER_NAME#')
85 $url = mb_substr(
$url, mb_strlen(
'#SERVER_NAME#'));
92 $dbSite = SiteTable::getList([
94 'select' => [
'LID',
'DIR',
'SERVER_NAME'],
99 $currentSite = $dbSite->fetch();
100 $serverName = $currentSite[
'SERVER_NAME'];
101 $url = str_replace(
'#SERVER_NAME#', $serverName,
$url);
static markToRegenerate(int $sitemapId)
static processIblock(int $iblockId)
static __callStatic($name, $arguments)
static prepareUrlToReplace($url, $siteId=null)
if(! $catalogEdit->isSuccess()) $iblock