[!!!][TASK] Remove support for XHTML 2 26/45526/4
authorBenni Mack <benni@typo3.org>
Wed, 30 Dec 2015 21:43:09 +0000 (22:43 +0100)
committerWouter Wolters <typo3@wouterwolters.nl>
Thu, 31 Dec 2015 12:18:23 +0000 (13:18 +0100)
The standard proposal was marked as canceled in
2009. TYPO3 v7 deprecated it, and all leftover code
is now removed.

Resolves: #72492
Releases: master
Change-Id: Ic3e6b9afb30510687a38bc916416285c168d2b7b
Reviewed-on: https://review.typo3.org/45526
Reviewed-by: Morton Jonuschat <m.jonuschat@mojocode.de>
Tested-by: Morton Jonuschat <m.jonuschat@mojocode.de>
Reviewed-by: Wouter Wolters <typo3@wouterwolters.nl>
Tested-by: Wouter Wolters <typo3@wouterwolters.nl>
typo3/sysext/core/Documentation/Changelog/master/Breaking-72492-RemovedXHTML2Support.rst [new file with mode: 0644]
typo3/sysext/frontend/Classes/ContentObject/ContentObjectRenderer.php
typo3/sysext/frontend/Classes/ContentObject/Menu/AbstractMenuContentObject.php
typo3/sysext/frontend/Classes/Page/PageGenerator.php
typo3/sysext/t3editor/Resources/Private/tsref.xml

diff --git a/typo3/sysext/core/Documentation/Changelog/master/Breaking-72492-RemovedXHTML2Support.rst b/typo3/sysext/core/Documentation/Changelog/master/Breaking-72492-RemovedXHTML2Support.rst
new file mode 100644 (file)
index 0000000..8787131
--- /dev/null
@@ -0,0 +1,20 @@
+=========================================
+Breaking: #72492 - Removed XHTML2 support
+=========================================
+
+Description
+===========
+
+The support for XHTML2 documents in the TYPO3 Frontend has been removed.
+
+
+Impact
+======
+
+The TypoScript option ``config.doctype = xhtml_2`` has no effect anymore.
+
+
+Affected Installations
+======================
+
+Any TYPO3 instance using XHTML2 for frontend rendering.
index 4d83003..7906830 100644 (file)
@@ -1223,7 +1223,7 @@ class ContentObjectRenderer
     }
 
     /**
-     * Returns the 'border' attribute for an <img> tag only if the doctype is not xhtml_strict, xhtml_11, xhtml_2 or html5
+     * Returns the 'border' attribute for an <img> tag only if the doctype is not xhtml_strict, xhtml_11 or html5
      * or if the config parameter 'disableImgBorderAttr' is not set.
      *
      * @param string $borderAttr The border attribute
@@ -1234,7 +1234,7 @@ class ContentObjectRenderer
         $tsfe = $this->getTypoScriptFrontendController();
         $docType = $tsfe->xhtmlDoctype;
         if (
-            $docType !== 'xhtml_strict' && $docType !== 'xhtml_11' && $docType !== 'xhtml_2'
+            $docType !== 'xhtml_strict' && $docType !== 'xhtml_11'
             && $tsfe->config['config']['doctype'] !== 'html5'
             && !$tsfe->config['config']['disableImgBorderAttr']
         ) {
@@ -1438,7 +1438,7 @@ class ContentObjectRenderer
             // Create TARGET-attribute only if the right doctype is used
             $target = '';
             $xhtmlDocType = $this->getTypoScriptFrontendController()->xhtmlDoctype;
-            if ($xhtmlDocType !== 'xhtml_strict' && $xhtmlDocType !== 'xhtml_11' && $xhtmlDocType !== 'xhtml_2') {
+            if ($xhtmlDocType !== 'xhtml_strict' && $xhtmlDocType !== 'xhtml_11') {
                 $target = isset($conf['target.'])
                     ? (string)$this->stdWrap($conf['target'], $conf['target.'])
                     : (string)$conf['target'];
@@ -6187,7 +6187,7 @@ class ContentObjectRenderer
         if ($JSwindowParams) {
             // Create TARGET-attribute only if the right doctype is used
             $xhtmlDocType = $tsfe->xhtmlDoctype;
-            if ($xhtmlDocType !== 'xhtml_strict' && $xhtmlDocType !== 'xhtml_11' && $xhtmlDocType !== 'xhtml_2') {
+            if ($xhtmlDocType !== 'xhtml_strict' && $xhtmlDocType !== 'xhtml_11') {
                 $target = ' target="FEopenLink"';
             } else {
                 $target = '';
index 180a8af..4d8f8c4 100644 (file)
@@ -256,8 +256,6 @@ abstract class AbstractMenuContentObject
                 // intended fall-through
             case 'xhtml_11':
                 // intended fall-through
-            case 'xhtml_2':
-                // intended fall-through
             case 'html5':
                 // intended fall-through
             case '':
index 0295b00..38b389c 100644 (file)
@@ -119,7 +119,7 @@ class PageGenerator
         if ($tsfe->config['config']['doctype']) {
             if (in_array(
                 (string)$tsfe->config['config']['doctype'],
-                array('xhtml_trans', 'xhtml_frames', 'xhtml_basic', 'xhtml_2', 'html5'),
+                array('xhtml_trans', 'xhtml_frames', 'xhtml_basic', 'html5'),
                 true)
             ) {
                 $tsfe->dtdAllowsFrames = true;
@@ -150,10 +150,6 @@ class PageGenerator
                 case 'xhtml+rdfa_10':
                     $tsfe->xhtmlVersion = 110;
                     break;
-                case 'xhtml_2':
-                    GeneralUtility::deprecationLog('The option "config.xhtmlDoctype=xhtml_2" is deprecated since TYPO3 CMS 7, and will be removed with CMS 8');
-                    $tsfe->xhtmlVersion = 200;
-                    break;
                 default:
                     static::getPageRenderer()->setRenderXhtml(false);
                     $tsfe->xhtmlDoctype = '';
@@ -289,11 +285,6 @@ class PageGenerator
     PUBLIC "-//W3C//DTD XHTML 1.1//EN"
     "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">';
                     break;
-                case 'xhtml_2':
-                    $docTypeParts[] = '<!DOCTYPE html
-    PUBLIC "-//W3C//DTD XHTML 2.0//EN"
-    "http://www.w3.org/TR/xhtml2/DTD/xhtml2.dtd">';
-                    break;
                 case 'xhtml+rdfa_10':
                     $docTypeParts[] = '<!DOCTYPE html
     PUBLIC "-//W3C//DTD XHTML+RDFa 1.0//EN"
index fdd34a3..5557421 100644 (file)
@@ -368,7 +368,6 @@ Use this feature in templates supplying other content-types than HTML. That coul
 "xhtml_basic" for XHTML basic doctype.
 "xhtml_11" for XHTML 1.1 doctype.
 "xhtml+rdf_10" for XHTML+RDFa 1.0 doctype.
-"xhtml_2" for XHTML 2 doctype.
 "html5" for HTML5
 "none" for NO doctype at all.
 
@@ -968,7 +967,6 @@ If config.doctype is set to a string then config.xhtmlDoctype must be set to one
 "xhtml_strict" for XHTML 1.0 Strict doctype.
 "xhtml_basic" for XHTML basic doctype.
 "xhtml_11" for XHTML 1.1 doctype.
-"xhtml_2" for XHTML 2 doctype.
 
 
 This is an example to use MathML 2.0 in an XHTML 1.1 document: