本文整理汇总了PHP中RunnerCipherer::GetLikeClause方法的典型用法代码示例。如果您正苦于以下问题:PHP RunnerCipherer::GetLikeClause方法的具体用法?PHP RunnerCipherer::GetLikeClause怎么用?PHP RunnerCipherer::GetLikeClause使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类RunnerCipherer
的用法示例。
在下文中一共展示了RunnerCipherer::GetLikeClause方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: array
$likeField = $searchByLinkField ? $linkFieldName : $displayFieldName;
} else {
$likeField = RunnerPage::_getFieldSQLDecrypt($searchByLinkField ? $linkFieldName : $displayFieldName, $lookupConnection, $lookupPSet, $cipherer);
}
} else {
$likeField = $cipherer->GetFieldName($lwDisplayField, $f);
}
if ($searchByLinkField) {
$likeConditionField = $LookupType == LT_QUERY ? $linkFieldName : $f;
} else {
$likeConditionField = $LookupType == LT_QUERY ? $displayFieldName : $f;
}
$likeWheres = array();
foreach ($values as $fieldValue) {
if ($LookupType == LT_QUERY) {
$likeWheres[] = $likeField . $lookupCipherer->GetLikeClause($likeConditionField, $fieldValue);
} else {
$likeWheres[] = $likeField . $cipherer->GetLikeClause($likeConditionField, $fieldValue);
}
}
$strLookupWhere .= implode(' OR ', $likeWheres);
if ($gSettings->useCategory($f) && ($isExistParent || postvalue('editMode') != MODE_SEARCH)) {
$arLookupWhere = array();
foreach ($lookupCategory as $arLookupCategory) {
$cvalue = make_db_value($gSettings->getCategoryControl($f), $arLookupCategory);
$arLookupWhere[] = $lookupConnection->addFieldWrappers($gSettings->getCategoryFilter($f)) . "=" . $cvalue;
}
$arLookupWhereToStr = count($arLookupWhere) == 1 ? $arLookupWhere[0] : "(" . implode(" OR ", $arLookupWhere) . ")";
if (count($arLookupWhere)) {
$strLookupWhere = whereAdd($strLookupWhere, $arLookupWhereToStr);
}
示例2: AddTableWrappers
$LookupSQLTable .= " FROM " . AddTableWrappers($lookupTable) . " ";
}
$strLookupWhere = GetLWWhere($f, $pageType, $strTableName);
if ($strLookupWhere) {
$strLookupWhere = " (" . $strLookupWhere . ") AND ";
}
if ($LookupType == LT_QUERY) {
if ($gSettings->getCustomDisplay($f)) {
$strLookupWhere .= $displayFieldName;
} else {
$strLookupWhere .= GetFullFieldName($displayFieldName, $lookupTable, false);
}
} else {
$strLookupWhere .= $cipherer->GetFieldName($lwDisplayField, $f);
}
$strLookupWhere .= $cipherer->GetLikeClause($LookupType == LT_QUERY ? $displayFieldName : $f, $value);
if ($gSettings->useCategory($f) && (postvalue("category") != '' || postvalue('editMode') != MODE_SEARCH)) {
$cvalue = make_db_value($gSettings->getCategoryControl($f), postvalue("category"));
$strLookupWhere .= " AND " . AddFieldWrappers($gSettings->getCategoryFilter($f)) . "=" . $cvalue;
}
$lookupOrderBy = $gSettings->getLookupOrderBy($f);
if (strlen($lookupOrderBy)) {
$lookupOrderBy = GetFullFieldName($lookupOrderBy, $lookupTable);
if ($gSettings->isLookupDesc($f)) {
$lookupOrderBy .= ' DESC';
}
}
if ($LookupType == LT_QUERY) {
$LookupSQL = $lookupQueryObj->toSql(whereAdd($lookupQueryObj->m_where->toSql($lookupQueryObj), $strLookupWhere), strlen($lookupOrderBy) ? ' ORDER BY ' . $lookupOrderBy : null);
} else {
$LookupSQL = $LookupSQLTable . " where " . $strLookupWhere;