Actions
Bug #17528
closedBEenableFields returns only ' AND ' in some cases
Start date:
2007-08-13
Due date:
% Done:
0%
Estimated time:
TYPO3 Version:
4.2
PHP Version:
4.3
Tags:
Complexity:
Is Regression:
Sprint Focus:
Description
If you call BEenableFields and nothing fits for the IF condition inside, then ' AND ' is returned. This is very bad, because it leads to a SQL error if this strange return value is not caught and not used to build a SQL query.
So this behaviour complicates the thing very much.
Solution:
$outQ = ($inv ? ($invQuery != '' ? '('.implode(' OR ',$invQuery).')' : '') : ($query != '' ? implode(' AND ',$query) : ''));
$outQ = ($outQ != '' ? ' AND '.$outQ : '');
(issue imported from #M6141)
Updated by Kasper Ligaard about 16 years ago
I think this could be closed because of this: http://bugs.typo3.org/view.php?id=9522
Actions