[TASK] Correct view webpage link anchor in list module 91/52391/2
authorGianluigi Martino <gmartino27@gmail.com>
Mon, 3 Apr 2017 12:18:46 +0000 (14:18 +0200)
committerMarkus Klein <markus.klein@typo3.org>
Fri, 7 Apr 2017 20:23:28 +0000 (22:23 +0200)
Without this patch you land to the top of the page if you open the preview
of a content element in list module. Adding "c" as letter to the anchor
link the browser scroll to the desired content element.

Resolves: #80598
Releases: master, 7.6
Change-Id: Ief0c3764a57911f9dd46dd7b9e19be964b0e2671
Reviewed-on: https://review.typo3.org/52391
Reviewed-by: Elmar Hinz <t3elmar@gmail.com>
Tested-by: TYPO3com <no-reply@typo3.com>
Reviewed-by: Markus Klein <markus.klein@typo3.org>
Tested-by: Markus Klein <markus.klein@typo3.org>
typo3/sysext/recordlist/Classes/RecordList/DatabaseRecordList.php

index 0bc635c..2456d8f 100644 (file)
@@ -1424,7 +1424,7 @@ class DatabaseRecordList extends AbstractDatabaseRecordList
                         ($table === 'tt_content' ? $this->id : $row['uid']),
                         '',
                         '',
-                        ($table === 'tt_content' ? '#' . $row['uid'] : '')
+                        ($table === 'tt_content' ? '#c' . $row['uid'] : '')
                     )
                 ) . '" title="' . $this->getLanguageService()->sL('LLL:EXT:lang/locallang_core.xlf:labels.showPage', true) . '">'
                 . $this->iconFactory->getIcon('actions-view', Icon::SIZE_SMALL)->render() . '</a>';