[BUGFIX] SoftReferenceIndex support for more values in class attribute 46/29846/2
authorMarc Bastian Heinrichs <typo3@mbh-software.de>
Sun, 4 May 2014 10:42:47 +0000 (12:42 +0200)
committerMarkus Klein <klein.t3@mfc-linz.at>
Sun, 4 May 2014 14:56:59 +0000 (16:56 +0200)
The SoftReferenceIndex parses and rebuilds typolink tags, but the
support for more than one value in class attribute is missing, because
the values don't get enclosed with quotes on rebuilding.
This leads to lost classes in typolinks in exports from impexp.

Resolves: #58484
Releases: 6.2, 6.1, 4.5
Change-Id: I12ed3be7f5be36254bcee57fcb24bf2a10f92f46
Reviewed-on: https://review.typo3.org/29846
Reviewed-by: Wouter Wolters
Reviewed-by: Sascha Wilking
Tested-by: Sascha Wilking
Reviewed-by: Markus Klein
Tested-by: Markus Klein
typo3/sysext/core/Classes/Database/SoftReferenceIndex.php

index a76ca15..8a9fa73 100644 (file)
@@ -793,7 +793,7 @@ class SoftReferenceIndex {
                if (strlen($content) && isset($tLP['target']) && $tLP['target'] !== '') {
                        $content .= ' ' . $tLP['target'];
                        if (isset($tLP['class']) && $tLP['class'] !== '') {
-                               $content .= ' ' . $tLP['class'];
+                               $content .= ' "' . $tLP['class'] . '"';
                                if (isset($tLP['title']) && $tLP['title'] !== '') {
                                        $content .= ' "' . $tLP['title'] . '"';
                                        if (isset($tLP['additionalParams']) && $tLP['additionalParams'] !== '') {