-
Notifications
You must be signed in to change notification settings - Fork 26
/
ext_localconf.php
32 lines (26 loc) · 1.4 KB
/
ext_localconf.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
<?php
defined('TYPO3_MODE') or die();
// adding th tx_seo_titletag to the pageOverlayFields so it is recognized when fetching the overlay fields
$GLOBALS['TYPO3_CONF_VARS']['FE']['pageOverlayFields'] .= ',tx_seo_titletag,tx_seo_canonicaltag,tx_seo_robots';
$extensionConfiguration = unserialize($GLOBALS['TYPO3_CONF_VARS']['EXT']['extConf']['seo_basics']);
// registering sitemap.xml for each hierachy of configuration to realurl (meaning to every website in a multisite installation)
if ($extensionConfiguration['xmlSitemap'] == '1') {
$realurl = $GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['realurl'];
$hooks = array('encodeSpURL_earlyHook', 'encodeSpURL_postProc', 'decodeSpURL_preProc', 'getHost', 'ConfigurationReader_postProc', 'storeInUrlCache');
if (is_array($realurl)) {
foreach ($realurl as $host => $cnf) {
// we won't do anything with string pointer (e.g. example.org => www.example.org)
// also ignore realurl hooks
if (!is_array($realurl[$host]) || in_array($host, $hooks, true)) {
continue;
}
if (!isset($realurl[$host]['fileName'])) {
$realurl[$host]['fileName'] = array();
}
$realurl[$host]['fileName']['index']['sitemap.xml']['keyValues']['type'] = 776;
}
$GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['realurl'] = $realurl;
}
}
$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['ext/install']['update']['seo_basics']
= \B13\SeoBasics\UpgradeWizard\ExtSeoUpgradeWizard::class;