if (rex_request('page') == 'seo42') { rex_register_extension('PAGE_HEADER', 'seo42_utils::appendToPageHeader'); } // check if seopage/urlpage needs to be enabled if (!$REX['ADDON']['seo42']['settings']['one_page_mode'] || $REX['ADDON']['seo42']['settings']['one_page_mode'] && $REX['ARTICLE_ID'] == $REX['START_ARTICLE_ID']) { if (isset($REX['USER']) && $REX['USER']->isAdmin()) { // admins get everything :) if (!$REX['ADDON']['seo42']['settings']['one_page_mode']) { // url page not needed when in one page mode seo42_utils::enableURLPage(); // injection order is important } seo42_utils::enableSEOPage(); } else { if (isset($REX['USER']) && $REX['USER']->hasPerm('seo42[url_default]')) { seo42_utils::enableURLPage(); } if (isset($REX['USER']) && ($REX['USER']->hasPerm('seo42[seo_default]') || $REX['USER']->hasPerm('seo42[seo_extended]') || $REX['USER']->hasPerm('editContentOnly[]'))) { seo42_utils::enableSEOPage(); } } } // fix article preview link as othewise not url types will show correct preview url rex_register_extension('PAGE_CONTENT_MENU', 'seo42_utils::fixArticlePreviewLink'); // check for missing db fields after db import if (!$REX['SETUP']) { rex_register_extension('A1_AFTER_DB_IMPORT', 'seo42_utils::afterDBImport'); } // if clang is added/deleted show message to the user that he should check his lang settings rex_register_extension('CLANG_ADDED', 'seo42_utils::showMsgAfterClangModified'); rex_register_extension('CLANG_DELETED', 'seo42_utils::showMsgAfterClangModified');