Project

General

Profile

Feature #17874 » 0006872_tceforms-suggest-v8-to-v9.diff

Administrator Admin, 2009-09-03 22:51

View differences:

t3lib/tceforms/class.t3lib_tceforms_suggest_defaultreceiver.php
$searchString = $this->params['value'];
$searchUid = intval($searchString);
if (strlen($searchString)) {
$this->selectClause = $GLOBALS['TCA'][$this->table]['ctrl']['label'] . ' LIKE \'' . ($searchWholePhrase ? '%' : '') . $GLOBALS['TYPO3_DB']->escapeStrForLike($searchString, $this->table).'%\'';
$likeCondition = ' LIKE \'' . ($searchWholePhrase ? '%' : '') .
$GLOBALS['TYPO3_DB']->escapeStrForLike($searchString, $this->table).'%\'';
$selectFields = array();
if (isset($GLOBALS['TCA'][$this->table]['ctrl']['label_alt'])) {
// Search in all fields given by label or label_alt
$selectFields = t3lib_div::trimExplode(',', $GLOBALS['TCA'][$this->table]['ctrl']['label_alt']);
}
$selectFields[] = $GLOBALS['TCA'][$this->table]['ctrl']['label'];
$selectParts = array();
foreach ($selectFields as $field) {
$selectParts[] = $field . $likeCondition;
}
$this->selectClause = implode(' OR ', $selectParts);
if ($searchUid > 0 && $searchUid == $searchString) {
$this->selectClause = '(' . $this->selectClause . ' OR uid = ' . $searchUid . ')';
}
typo3/stylesheet.css
list-style-type:none;
display:block;
margin:0;
padding:2px;
padding-left:24px;
height:32px;
padding:4px 2px 4px 24px;
cursor:pointer;
background-color:#EFEFF4;
background-repeat:no-repeat;
(12-12/12)