Project

General

Profile

Actions

Task #92465

closed

TCA eval 'alpha' discards umlaut characters

Added by Remo Schneider about 4 years ago. Updated almost 4 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
Backend JavaScript
Target version:
-
Start date:
2020-10-01
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
10
PHP Version:
7.4
Tags:
Complexity:
Sprint Focus:

Description

I'm unable to insert special characters like 'ä' into an input field that is configured with

'eval' => 'alpha'
in TCA, however, 'alpha' is the only available option against non-word characters.

It should at least be mentioned in the documentation, or, if possible, adjusted to allow characters beyond A-Z that are no spaces, numbers or other non-word characters.

System overview:
TYPO3 Version 10.4.9
Webserver Apache/2.4.38 (Debian)
PHP Version 7.4.9
Database (Default) MySQL 5.7.29
Application Context Development
Operating System Linux 4.15.0-118-generic

Actions #1

Updated by Guido Schmechel about 4 years ago

HI Remo, i found this documentation: https://docs.typo3.org/m/typo3/reference-tca/master/en-us/ColumnsConfig/Type/inputDefault.html?highlight=eval#id15 I think "alpha" is correctly documented.

My opinion: If we include the umlauts in this list, other eval functions are also affected, then we would have to consider other languages/characters. Example: Chinese, Greece or something else.

There is a hook and you can define your own "alpha" eval function:

$value = preg_replace('/[^a-zäöüA-ZÄÖÜß]/', '', $value);

Maybe this will help you?

Actions #2

Updated by Remo Schneider about 4 years ago

Yes, thank you! I will use the hook then.

Actions #3

Updated by Andreas Kienast almost 4 years ago

  • Status changed from New to Closed

Closed as this issue can be solved via custom implementation.

Actions #4

Updated by Martin Kutschker almost 4 years ago

Well, the term alphabet only applies to Latin letters: \p{Latin} (maybe used together with \p{L})

Actions

Also available in: Atom PDF