Bug #89390

Slug generation: Fallback fields seems not to work

Added by Alex Kellner about 1 month ago. Updated about 1 month ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
-
Target version:
-
Start date:
2019-10-10
Due date:
% Done:

0%

TYPO3 Version:
9
PHP Version:
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

TYPO3 9.5.9

Target: We want to use pages.nav_title for slug generation of pages and if nav_title is empty, title should be used instead.
Luckily there is a good documentation that describes this scenario exactly:
https://docs.typo3.org/m/typo3/reference-tca/9.5/en-us/ColumnsConfig/Type/Slug.html#generatoroptions

Problem: If pages.nav_title and pages.title is filled and the slug will be regenerated, values of both fields are used to fill the slug.

If I follow the recommendation, this TCA should work as described:

$GLOBALS['TCA']['pages']['columns']['slug']['config']['generatorOptions']['fields'] = ['nav_title', 'title'];

The complete TCA for pages.slug:

The problem:

History

#1 Updated by Alex Kellner about 1 month ago

The correct configuration would be:

$GLOBALS['TCA']['pages']['columns']['slug']['config']['generatorOptions']['fields'] = [['nav_title', 'title']];

Please close this issue (and maybe a documentation update would be fine for the next integrator)

#2 Updated by Georg Ringer about 1 month ago

  • Status changed from New to Closed

#3 Updated by Daniel Siepmann about 1 month ago

There were Pull Requests fixing wrong documentation. Thanks for pointing out.

Also available in: Atom PDF