From: Matthias Schmidt Date: Fri, 23 Oct 2020 14:15:14 +0000 (+0200) Subject: Remove metaKeywords from page PIP X-Git-Tag: 5.4.0_Alpha_1~712^2~5 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=be636ae4adbf3a6d3996e3259f9f00201870bc89;p=GitHub%2FWoltLab%2FWCF.git Remove metaKeywords from page PIP --- diff --git a/wcfsetup/install/files/lib/system/package/plugin/PagePackageInstallationPlugin.class.php b/wcfsetup/install/files/lib/system/package/plugin/PagePackageInstallationPlugin.class.php index 9a0c0b29fb..48e80af4f5 100644 --- a/wcfsetup/install/files/lib/system/package/plugin/PagePackageInstallationPlugin.class.php +++ b/wcfsetup/install/files/lib/system/package/plugin/PagePackageInstallationPlugin.class.php @@ -135,7 +135,6 @@ class PagePackageInstallationPlugin extends AbstractXMLPackageInstallationPlugin 'content' => (!empty($contentData['content'])) ? StringUtil::trim($contentData['content']) : '', 'customURL' => (!empty($contentData['customURL'])) ? StringUtil::trim($contentData['customURL']) : '', 'metaDescription' => (!empty($contentData['metaDescription'])) ? StringUtil::trim($contentData['metaDescription']) : '', - 'metaKeywords' => (!empty($contentData['metaKeywords'])) ? StringUtil::trim($contentData['metaKeywords']) : '', 'title' => (!empty($contentData['title'])) ? StringUtil::trim($contentData['title']) : '' ]; } @@ -348,7 +347,7 @@ class PagePackageInstallationPlugin extends AbstractXMLPackageInstallationPlugin $statement = WCF::getDB()->prepareStatement($sql); $sql = "INSERT IGNORE INTO wcf".WCF_N."_page_content - (pageID, languageID, title, content, metaDescription, metaKeywords, customURL) + (pageID, languageID, title, content, metaDescription, customURL) VALUES (?, ?, ?, ?, ?, ?, ?)"; $insertStatement = WCF::getDB()->prepareStatement($sql); @@ -374,8 +373,7 @@ class PagePackageInstallationPlugin extends AbstractXMLPackageInstallationPlugin $content['title'], $content['content'], $content['metaDescription'], - $content['metaKeywords'], - $content['customURL'] + $content['customURL'], ]); // generate template if page's type is 'tpl' @@ -598,13 +596,6 @@ class PagePackageInstallationPlugin extends AbstractXMLPackageInstallationPlugin ->i18n() ->i18nRequired() ->languageItemPattern('__NONE__'), - - TextFormField::create('contentMetaKeywords') - ->objectProperty('metaKeywords') - ->label('wcf.acp.pip.page.contentMetaKeywords') - ->i18n() - ->i18nRequired() - ->languageItemPattern('__NONE__'), ]); // dependencies @@ -619,7 +610,7 @@ class PagePackageInstallationPlugin extends AbstractXMLPackageInstallationPlugin ); } - foreach (['contentContent', 'contentCustomURL', 'contentMetaDescription', 'contentMetaKeywords'] as $nonSystemElement) { + foreach (['contentContent', 'contentCustomURL', 'contentMetaDescription'] as $nonSystemElement) { $form->getNodeById($nonSystemElement)->addDependency( ValueFormFieldDependency::create('pageType') ->field($pageType) @@ -644,7 +635,6 @@ class PagePackageInstallationPlugin extends AbstractXMLPackageInstallationPlugin 'content' => [], 'customURL' => [], 'metaDescription' => [], - 'metaKeywords' => [] ]; /** @var \DOMElement $name */ @@ -682,7 +672,7 @@ class PagePackageInstallationPlugin extends AbstractXMLPackageInstallationPlugin } $readData = function($languageID, \DOMElement $content) use (&$data, $saveData) { - foreach (['title', 'content', 'customURL', 'metaDescription', 'metaKeywords'] as $contentElementName) { + foreach (['title', 'content', 'customURL', 'metaDescription'] as $contentElementName) { $contentElement = $content->getElementsByTagName($contentElementName)->item(0); if (!isset($data[$contentElementName])) { $data[$contentElementName] = []; @@ -740,7 +730,7 @@ class PagePackageInstallationPlugin extends AbstractXMLPackageInstallationPlugin $content = []; - foreach (['title', 'content', 'customURL', 'metaDescription', 'metaKeywords'] as $contentProperty) { + foreach (['title', 'content', 'customURL', 'metaDescription'] as $contentProperty) { if (!empty($data[$contentProperty])) { foreach ($data[$contentProperty] as $languageID => $value) { $languageCode = LanguageFactory::getInstance()->getLanguage($languageID)->languageCode; @@ -757,7 +747,7 @@ class PagePackageInstallationPlugin extends AbstractXMLPackageInstallationPlugin } foreach ($content as $languageCode => $values) { - foreach (['title', 'content', 'customURL', 'metaDescription', 'metaKeywords'] as $contentProperty) { + foreach (['title', 'content', 'customURL', 'metaDescription'] as $contentProperty) { if (!isset($values[$contentProperty])) { $content[$languageCode][$contentProperty] = ''; } @@ -858,7 +848,7 @@ class PagePackageInstallationPlugin extends AbstractXMLPackageInstallationPlugin foreach ($languages as $language) { $content = null; - foreach (['title', 'content', 'customURL', 'metaDescription', 'metaKeywords'] as $property) { + foreach (['title', 'content', 'customURL', 'metaDescription'] as $property) { if (!empty($formData[$property . '_i18n'][$language->languageID])) { if ($content === null) { $content = $document->createElement('content'); diff --git a/wcfsetup/install/lang/de.xml b/wcfsetup/install/lang/de.xml index 577be3b506..9062ac6d36 100644 --- a/wcfsetup/install/lang/de.xml +++ b/wcfsetup/install/lang/de.xml @@ -2552,7 +2552,6 @@ Kein Abschnitt darf leer sein und alle Abschnitten dürfen nur folgende Zeichen - diff --git a/wcfsetup/install/lang/en.xml b/wcfsetup/install/lang/en.xml index c20e910ab4..01affdf20d 100644 --- a/wcfsetup/install/lang/en.xml +++ b/wcfsetup/install/lang/en.xml @@ -2324,7 +2324,6 @@ If you have already bought the licenses for the listed apps, th -