当前位置: 首页>>代码示例>>PHP>>正文


PHP RunnerCipherer::GetLikeClause方法代码示例

本文整理汇总了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);
     }
开发者ID:kcallow,项目名称:MatchMe,代码行数:31,代码来源:lookupsuggest.php

示例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;
开发者ID:aagusti,项目名称:padl-tng,代码行数:31,代码来源:lookupsuggest.php


注:本文中的RunnerCipherer::GetLikeClause方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。