Project

General

Profile

Actions

Bug #65965

closed

Wrong $paramsList in FormEngine->getSingleField_typeInput

Added by Klaus Moser about 9 years ago. Updated over 5 years ago.

Status:
Closed
Priority:
Must have
Assignee:
Category:
Backend API
Target version:
Start date:
2015-03-24
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
6.2
PHP Version:
Tags:
Complexity:
no-brainer
Is Regression:
No
Sprint Focus:

Description

Found a bug in line 1537 in method getSingleField_typeInput in class FormEngine:

Is:

$paramsList = '\'' . $PA['itemFormElName'] . '\',\'' . implode(',', $evalList) . '\',\'' . trim($config['is_in']) . '\',' . (isset($config['checkbox']) ? 1 : 0) . ',\'' . $config['checkbox'] . '\'';

Must be:

$paramsList = '\'' . $PA['itemFormElName'] . '\',\'' . implode(',', $evalList) . '\',\'' . trim($config['is_in']) . '\',' . ($checkboxIsset ? 1 : 0) . ',\'' . $config['checkbox'] . '\'';

If $config['checkbox'] is not set it gets set in line 1449ff.

if (!isset($config['checkbox'])) {
    $config['checkbox'] = '0';
    $checkboxIsset = FALSE;
} else {
    $checkboxIsset = TRUE;
}

So isset($config['checkbox'] is always true.

This causes the forth paramter of the JS method fieldGet to be always 1 and there is no possibility to allow the value 0 in an textfield that evaluates to an integer value.


Related issues 2 (1 open1 closed)

Related to TYPO3 Core - Bug #23763: Enable "clear input field" functionality by defaultClosedJeff Segars2010-10-17

Actions
Related to TYPO3 Core - Bug #68303: Image width/height are displayed as 0 in backend for default dimensionsNew

Actions
Actions

Also available in: Atom PDF