Project

General

Profile

Actions

Bug #84016

closed

impexp: page links are parsed / replaced incorrectely due to error in SoftReferenceIndex

Added by Markus Stauffiger over 6 years ago. Updated almost 5 years ago.

Status:
Closed
Priority:
Must have
Assignee:
-
Category:
Site Handling, Site Sets & Routing
Target version:
-
Start date:
2018-02-22
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
8
PHP Version:
Tags:
Complexity:
hard
Is Regression:
Sprint Focus:

Description

With the new handling of the link field in the backend, the page links, e.g. in the header_link field of a content element, are not parsed correctly and therefore not replaced during the import.

TYPO3 7

TYPO3 8

I think the problem is within the SoftReferenceIndex, so the bug might actually be in core and not impexp.


Files

typo3_7.png (61.2 KB) typo3_7.png Markus Stauffiger, 2018-02-22 21:52
typo3_8.png (63.5 KB) typo3_8.png Markus Stauffiger, 2018-02-22 21:52
yuno_page.png (97.4 KB) yuno_page.png Markus Stauffiger, 2018-02-22 22:50
patch_gaya.diff (9.41 KB) patch_gaya.diff Rémy DANIEL, 2019-09-10 18:52

Related issues 5 (0 open5 closed)

Related to TYPO3 Core - Bug #85576: Linkvalidator not checking linked content elements with TypoLinkClosed2018-07-16

Actions
Related to TYPO3 Core - Bug #87652: SoftReferenceIndex :: TypoLink :: links like "t3:// FileLinks" won't be recognizedClosed2019-02-05

Actions
Related to TYPO3 Core - Bug #88207: SoftReferenceIndex is missing support for t3://file uriClosed2019-04-25

Actions
Related to TYPO3 Core - Bug #83377: Soft Reference Index is broken for filesClosed2017-12-18

Actions
Related to TYPO3 Core - Bug #86628: Linked files not referenced in backend filelistClosed2018-10-11

Actions
Actions #1

Updated by Markus Stauffiger over 6 years ago

  • Subject changed from impexp: page links are parsed / replaced correctely to impexp: page links are parsed / replaced incorrectely
Actions #2

Updated by Markus Stauffiger over 6 years ago

  • File yuno_page.png yuno_page.png added
  • Subject changed from impexp: page links are parsed / replaced incorrectely to impexp: page links are parsed / replaced incorrectely due to error in SoftReferenceIndex
  • Category changed from Import/Export (T3D) to Site Handling, Site Sets & Routing

The bug is within the SoftReferenceIndex.

Arriving at https://github.com/TYPO3/TYPO3.CMS/blob/master/typo3/sysext/core/Classes/Database/SoftReferenceIndex.php#L499 $containsSlash || $isLocalFile it decides that a t3://page link is a local file and therefore does not get to the part where it's marked as a page.

Actions #3

Updated by Markus Klein over 6 years ago

Hi!

Thanks for reporting and analysis.

Can you push a patch with a solution?
(https://docs.typo3.org/typo3cms/ContributionWorkflowGuide/ if you need a first-time setup)

Actions #4

Updated by Rémy DANIEL over 6 years ago

@Markus Klein, I've quickly patched the SoftReferenceIndex for a single usecase.

But it seems SoftReferenceIndex needs a huge rewrite because the new link handling (t3://) is not well handled by the SoftReferenceIndex.
For example, a link in tt_content.header_link (typolink) or in tt_content.bodytext (typoling_tag) will not be referenced the same way in the database.
Also, a link to a record (t3://record) is not referenced at all.

I think I'm not the guy who can handle this rewrite because it too difficult for my skills...

Actions #5

Updated by Rémy DANIEL over 6 years ago

  • Complexity changed from medium to hard
Actions #6

Updated by Gerrit Code Review over 6 years ago

  • Status changed from New to Under Review

Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/57610

Actions #7

Updated by Patrick Broens over 6 years ago

Also the core extension "linkvalidator" is suffering from this.

To reproduce:
  • Install the extension "linkvalidator"
  • Make a content element on a page with the field "header_link" filled with t3://page?uid=5000, where 5000 is a non existing page in your database
  • Go to the module "Web > Info > Linkvalidator" and check the links on the page
  • The page mentioned in this field will not show up in the report or in the "Internal links" counter.

You can do the same with t3://file?uid=5000

TypoLinks used in the RTE in an anchor tag are fine.

Actions #8

Updated by Gerrit Code Review over 6 years ago

Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/57610

Actions #9

Updated by Patrick Broens over 6 years ago

  • Related to Bug #85576: Linkvalidator not checking linked content elements with TypoLink added
Actions #10

Updated by Patrick Broens over 6 years ago

  • Related to Epic #85006: Reduce falsely reported broken links added
Actions #11

Updated by Gerrit Code Review over 6 years ago

Patch set 3 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/57610

Actions #12

Updated by Gerrit Code Review about 6 years ago

Patch set 4 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/57610

Actions #13

Updated by Gerrit Code Review about 6 years ago

Patch set 5 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/57610

Actions #14

Updated by Gerrit Code Review about 6 years ago

Patch set 6 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/57610

Actions #15

Updated by Gerrit Code Review about 6 years ago

Patch set 7 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/57610

Actions #16

Updated by Gerrit Code Review about 6 years ago

Patch set 8 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/57610

Actions #17

Updated by Gerrit Code Review almost 6 years ago

Patch set 9 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/57610

Actions #18

Updated by Rémy DANIEL about 5 years ago

I've fixed this issue, and another one about handling of the anchor in links for a specific project.
I've attached the patch for the fix, it may be useful.

Actions #19

Updated by Markus Klein about 5 years ago

@Daniel Hinderink Would you mind pushing your patch to the review system?

Actions #20

Updated by Rémy DANIEL about 5 years ago

There is already a patch in review: https://review.typo3.org/c/Packages/TYPO3.CMS/+/57610/

Should I amend the existing patch?

Actions #21

Updated by Markus Klein about 5 years ago

Sure, feel free

Actions #22

Updated by Gerrit Code Review about 5 years ago

Patch set 10 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/57610

Actions #23

Updated by Gerrit Code Review about 5 years ago

Patch set 11 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/57610

Actions #24

Updated by Gerrit Code Review about 5 years ago

Patch set 12 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/57610

Actions #25

Updated by Gerrit Code Review about 5 years ago

Patch set 13 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/57610

Actions #26

Updated by Gerrit Code Review about 5 years ago

Patch set 14 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/57610

Actions #27

Updated by Gerrit Code Review about 5 years ago

Patch set 15 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/57610

Actions #28

Updated by Gerrit Code Review about 5 years ago

Patch set 16 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/57610

Actions #29

Updated by Gerrit Code Review about 5 years ago

Patch set 17 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/57610

Actions #30

Updated by Benni Mack about 5 years ago

  • Related to Bug #87652: SoftReferenceIndex :: TypoLink :: links like "t3:// FileLinks" won't be recognized added
Actions #31

Updated by Benni Mack about 5 years ago

  • Related to Bug #88207: SoftReferenceIndex is missing support for t3://file uri added
Actions #32

Updated by Gerrit Code Review about 5 years ago

Patch set 1 for branch 9.5 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/62143

Actions #33

Updated by Gerrit Code Review about 5 years ago

Patch set 2 for branch 9.5 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/62143

Actions #34

Updated by Rémy DANIEL about 5 years ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100
Actions #35

Updated by Benni Mack about 5 years ago

  • Related to Bug #83377: Soft Reference Index is broken for files added
Actions #36

Updated by Benni Mack about 5 years ago

  • Related to Bug #86628: Linked files not referenced in backend filelist added
Actions #37

Updated by Sybille Peters about 5 years ago

  • Related to deleted (Epic #85006: Reduce falsely reported broken links)
Actions #38

Updated by Benni Mack almost 5 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF