[BUGFIX] Report not shown in IE 7 and 8 when CheckLink tab is hidden
authorDaniel Minder <daniel.minder@uni-due.de>
Fri, 15 Mar 2013 16:12:52 +0000 (17:12 +0100)
committerPhilipp Gampe <philipp.gampe@typo3.org>
Sat, 16 Mar 2013 18:04:07 +0000 (19:04 +0100)
With showCheckLinkTab = 0 linkvalidator does not load in IE 7 and 8
since trailing commas in array literals are not ignored. This leads to a
JavaScript error in ExtJS.

Solution: Output comma only when the CheckLink tab is added.

Resolves: #36515
Releases: 4.7, 6.0, 6.1
Change-Id: I8e6441f48664da2bd400c4e9b14179f6f520320f
Reviewed-on: https://review.typo3.org/18953
Reviewed-by: Wouter Wolters
Tested-by: Wouter Wolters
Reviewed-by: Philipp Gampe
Tested-by: Philipp Gampe
typo3/sysext/linkvalidator/Classes/Report/LinkValidatorReport.php

index b459cff..b1bd988 100644 (file)
@@ -237,7 +237,8 @@ class LinkValidatorReport extends \TYPO3\CMS\Backend\Module\AbstractFunctionModu
        protected function createTabs() {
                $panelCheck = '';
                if ($this->modTS['showCheckLinkTab'] == 1) {
-                       $panelCheck = '{
+                       $panelCheck = ',
+                       {
                                title: TYPO3.l10n.localize(\'CheckLink\'),
                                html: ' . json_encode($this->flush()) . ',
                        }';
@@ -254,8 +255,7 @@ class LinkValidatorReport extends \TYPO3\CMS\Backend\Module\AbstractFunctionModu
                                autoHeight: true,
                                title: TYPO3.l10n.localize(\'Report\'),
                                html: ' . json_encode($this->flush(TRUE)) . '
-                       },
-                       ' . $panelCheck . '
+                       }' . $panelCheck . '
                        ]
 
                });
@@ -718,4 +718,4 @@ class LinkValidatorReport extends \TYPO3\CMS\Backend\Module\AbstractFunctionModu
 }
 
 
-?>
\ No newline at end of file
+?>