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


PHP CDBResult::GetNext方法代码示例

本文整理汇总了PHP中CDBResult::GetNext方法的典型用法代码示例。如果您正苦于以下问题:PHP CDBResult::GetNext方法的具体用法?PHP CDBResult::GetNext怎么用?PHP CDBResult::GetNext使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在CDBResult的用法示例。


在下文中一共展示了CDBResult::GetNext方法的12个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: CDBResult

 $arHistoryFirst = $rsHistoryFirst->GetNext();
 $rsHistory = new CDBResult($dbResultList, $sTableID);
 $rsHistory->NavStart($arParams['HISTORY_COUNT'], false);
 $arResult['DB_LIST'] =& $rsHistory;
 $arResult['HISTORY'] = array();
 if ($arResult['SOCNET']) {
     $arResult['AJAX_PAGE'] = $APPLICATION->GetCurPageParam('', array('bxajaxid', 'logout'));
     $arResult['PATH_TO_USER'] = $arParams['PATH_TO_USER'];
     $arResult['SHOW_LOGIN'] = $this->GetParent()->arParams['SHOW_LOGIN'];
     $arResult['NAME_TEMPLATE'] = $this->GetParent()->arParams['NAME_TEMPLATE'];
     $arResult['PATH_TO_CONPANY_DEPARTMENT'] = $this->GetParent()->arParams['PATH_TO_CONPANY_DEPARTMENT'];
     $arResult['PATH_TO_VIDEO_CALL'] = $this->GetParent()->arParams['PATH_TO_VIDEO_CALL'];
     $arResult['PATH_TO_SONET_MESSAGES_CHAT'] = $this->GetParent()->arParams['PATH_TO_MESSAGES_CHAT'];
 }
 $arErrorsTmp = array();
 while ($arHistory = $rsHistory->GetNext()) {
     $arHistory['USER_LINK'] = '';
     $arHistoryResult = CBPDocument::GetDocumentFromHistory($arHistory['ID'], $arErrorsTmp);
     $arHistory["MODIFY_COMMENT"] = $arHistoryResult["DOCUMENT"]["MODIFY_COMMENT"];
     if (!empty($arParams['PATH_TO_USER'])) {
         $arHistory['USER_LINK'] = CHTTP::urlAddParams(CComponentEngine::MakePathFromTemplate($arParams['PATH_TO_USER'], array('wiki_name' => urlencode($arParams['ELEMENT_NAME']), 'group_id' => CWikiSocnet::$iSocNetId, 'user_id' => $arHistory['USER_ID'])), array());
     }
     /*CBPHistoryService::GetHistoryList() returns specialchared values
     		and CWikiUtils::GetUserLogin also do htmlspecialchars*/
     foreach (array('USER_LOGIN', 'USER_NAME', 'USER_LAST_NAME', 'USER_SECOND_NAME') as $key) {
         $arHistory[$key] = CWikiUtils::htmlspecialchars_decode($arHistory[$key]);
     }
     $arHistory['USER_LOGIN'] = CWikiUtils::GetUserLogin($arHistory, $arParams["NAME_TEMPLATE"]);
     $arHistory['DISCUSSION_LINK'] = CHTTP::urlAddParams(CComponentEngine::MakePathFromTemplate($arParams['PATH_TO_DISCUSSION'], array('wiki_name' => urlencode($arParams['ELEMENT_NAME']), 'group_id' => CWikiSocnet::$iSocNetId)), $arParams['IN_COMPLEX'] == 'Y' && $arParams['SEF_MODE'] == 'N' ? array($arParams['OPER_VAR'] => 'discussion') : array());
     $arHistory['SHOW_LINK'] = CHTTP::urlAddParams(CComponentEngine::MakePathFromTemplate($arParams['PATH_TO_POST'], array('wiki_name' => urlencode($arParams['ELEMENT_NAME']), 'group_id' => CWikiSocnet::$iSocNetId)), array('oldid' => $arHistory['ID']));
     $arHp = array('oldid' => $arHistory['ID'], 'sessid' => bitrix_sessid());
开发者ID:k-kalashnikov,项目名称:geekcon_new,代码行数:31,代码来源:component.php

示例2: GetNext

 function GetNext($bTextHtmlAuto = true, $use_tilda = true)
 {
     static $arSectionPathCache = array();
     $res = parent::GetNext($bTextHtmlAuto, $use_tilda);
     if ($res) {
         //Handle List URL for Element, Section or IBlock
         if ($this->strListUrl) {
             $TEMPLATE = $this->strListUrl;
         } elseif (array_key_exists("~LIST_PAGE_URL", $res)) {
             $TEMPLATE = $res["~LIST_PAGE_URL"];
         } elseif (!$use_tilda && array_key_exists("LIST_PAGE_URL", $res)) {
             $TEMPLATE = $res["LIST_PAGE_URL"];
         } else {
             $TEMPLATE = "";
         }
         if ($TEMPLATE) {
             $res_tmp = $res;
             if (intval($res["IBLOCK_ID"]) <= 0 && intval($res["ID"]) > 0) {
                 $res_tmp["IBLOCK_ID"] = $res["ID"];
                 $res_tmp["IBLOCK_CODE"] = $res["CODE"];
                 $res_tmp["IBLOCK_EXTERNAL_ID"] = $res["EXTERNAL_ID"];
                 if ($use_tilda) {
                     $res_tmp["~IBLOCK_ID"] = $res["~ID"];
                     $res_tmp["~IBLOCK_CODE"] = $res["~CODE"];
                     $res_tmp["~IBLOCK_EXTERNAL_ID"] = $res["~EXTERNAL_ID"];
                 }
             }
             if ($use_tilda) {
                 $res["~LIST_PAGE_URL"] = CIBlock::ReplaceDetailUrl($TEMPLATE, $res_tmp, true, false);
                 $res["LIST_PAGE_URL"] = htmlspecialcharsbx($res["~LIST_PAGE_URL"]);
             } else {
                 $res["LIST_PAGE_URL"] = CIBlock::ReplaceDetailUrl($TEMPLATE, $res_tmp, true, false);
             }
         }
         //If this is Element or Section then process it's detail and section URLs
         if (strlen($res["IBLOCK_ID"])) {
             if (array_key_exists("GLOBAL_ACTIVE", $res)) {
                 $type = "S";
             } else {
                 $type = "E";
             }
             if ($this->strDetailUrl) {
                 $TEMPLATE = $this->strDetailUrl;
             } elseif (array_key_exists("~DETAIL_PAGE_URL", $res)) {
                 $TEMPLATE = $res["~DETAIL_PAGE_URL"];
             } elseif (!$use_tilda && array_key_exists("DETAIL_PAGE_URL", $res)) {
                 $TEMPLATE = $res["DETAIL_PAGE_URL"];
             } else {
                 $TEMPLATE = "";
             }
             if ($TEMPLATE) {
                 if ($this->arSectionContext) {
                     $TEMPLATE = str_replace("#SECTION_ID#", $this->arSectionContext["ID"], $TEMPLATE);
                     $TEMPLATE = str_replace("#SECTION_CODE#", $this->arSectionContext["CODE"], $TEMPLATE);
                     if ($this->arSectionContext["ID"] > 0 && $this->arSectionContext["IBLOCK_ID"] > 0 && strpos($TEMPLATE, "#SECTION_CODE_PATH#") !== false) {
                         if (!array_key_exists($this->arSectionContext["ID"], $arSectionPathCache)) {
                             $rs = CIBlockSection::GetNavChain($this->arSectionContext["IBLOCK_ID"], $this->arSectionContext["ID"], array("ID", "IBLOCK_SECTION_ID", "CODE"));
                             while ($a = $rs->Fetch()) {
                                 $arSectionPathCache[$this->arSectionContext["ID"]] .= urlencode($a["CODE"]) . "/";
                             }
                         }
                         if (isset($arSectionPathCache[$this->arSectionContext["ID"]])) {
                             $SECTION_CODE_PATH = rtrim($arSectionPathCache[$this->arSectionContext["ID"]], "/");
                         } else {
                             $SECTION_CODE_PATH = "";
                         }
                         $TEMPLATE = str_replace("#SECTION_CODE_PATH#", $SECTION_CODE_PATH, $TEMPLATE);
                     }
                 }
                 if ($use_tilda) {
                     $res["~DETAIL_PAGE_URL"] = CIBlock::ReplaceDetailUrl($TEMPLATE, $res, true, $type);
                     $res["DETAIL_PAGE_URL"] = htmlspecialcharsbx($res["~DETAIL_PAGE_URL"]);
                 } else {
                     $res["DETAIL_PAGE_URL"] = CIBlock::ReplaceDetailUrl($TEMPLATE, $res, true, $type);
                 }
             }
             if ($this->strSectionUrl) {
                 $TEMPLATE = $this->strSectionUrl;
             } elseif (array_key_exists("~SECTION_PAGE_URL", $res)) {
                 $TEMPLATE = $res["~SECTION_PAGE_URL"];
             } elseif (!$use_tilda && array_key_exists("SECTION_PAGE_URL", $res)) {
                 $TEMPLATE = $res["SECTION_PAGE_URL"];
             } else {
                 $TEMPLATE = "";
             }
             if ($TEMPLATE) {
                 if ($use_tilda) {
                     $res["~SECTION_PAGE_URL"] = CIBlock::ReplaceSectionUrl($TEMPLATE, $res, true, $type);
                     $res["SECTION_PAGE_URL"] = htmlspecialcharsbx($res["~SECTION_PAGE_URL"]);
                 } else {
                     $res["SECTION_PAGE_URL"] = CIBlock::ReplaceSectionUrl($TEMPLATE, $res, true, $type);
                 }
             }
         }
     }
     return $res;
 }
开发者ID:spas-viktor,项目名称:books,代码行数:97,代码来源:iblockresult.php

示例3: GetNext

 function GetNext()
 {
     global $DB;
     if ($res = parent::GetNext()) {
         $result = $res;
         foreach ($res as $key => $val) {
             if (substr($key, 0, 2) == "~~") {
                 unset($result[$key]);
                 $result[substr($key, 1)] = $val;
             }
         }
     }
     return $result;
 }
开发者ID:DarneoStudio,项目名称:bitrix,代码行数:14,代码来源:file.php

示例4: ShowError

     ShowError(GetMessage('WIKI_ACCESS_DENIED'));
     return;
 }
 if (!empty($arHistoryResult)) {
     $history = new CBPHistoryService();
     $arFilter = array('DOCUMENT_ID' => $documentId);
     $dbResultList = $history->GetHistoryList(array('ID' => 'DESC'), $arFilter, false, false, array('ID'));
     $sTableID = 'tbl_bizproc_document_history';
     $rsHistory = new CDBResult($dbResultList, $sTableID);
     $iPrevHistoryId = 0;
     $iNextHistoryId = 0;
     $iCurHistoryId = 0;
     $arPrevHistory = array();
     $arNextHistory = array();
     $bFirst = true;
     while ($arHistory = $rsHistory->GetNext()) {
         if ($bFirst) {
             $bFirst = false;
             $iCurHistoryId = $arHistory['ID'];
         }
         if ($arHistory['ID'] == $historyId) {
             $arPrevHistory = $rsHistory->GetNext();
             break;
         }
         $arNextHistory = $arHistory;
     }
     if (!empty($arPrevHistory)) {
         $iPrevHistoryId = $arPrevHistory['ID'];
     }
     if (!empty($arNextHistory)) {
         $iNextHistoryId = $arNextHistory['ID'];
开发者ID:k-kalashnikov,项目名称:geekcon_new,代码行数:31,代码来源:component.php

示例5: GetNext

 function GetNext()
 {
     $res = parent::GetNext();
     if ($res) {
         if (strlen($res["DESCRIPTION"]) > 0) {
             $res["DESCRIPTION"] = $this->ConvertBBCode($res["DESCRIPTION"]);
         }
     }
     return $res;
 }
开发者ID:mrdeadmouse,项目名称:u136006,代码行数:10,代码来源:taskservice.php

示例6: GetNext

 public static function GetNext($bTextHtmlAuto = true, $use_tilda = true)
 {
     $r = parent::GetNext($bTextHtmlAuto, $use_tilda);
     if ($r) {
         $r["VALUE"] = str_repeat(" . ", $r["DEPTH_LEVEL"]) . $r["NAME"];
     }
     return $r;
 }
开发者ID:rasuldev,项目名称:torino,代码行数:8,代码来源:usertypesection.php

示例7: GetModuleEvents

$catParams->bIsRed = 'N';
$catParams->createLinkFromTemplate();
$categories->addItem($catParams);
//Anyone can add custom virtual category to the list
$rsHandlers = GetModuleEvents("wiki", "OnCategoryListCreate");
while ($arHandler = $rsHandlers->Fetch()) {
    ExecuteModuleEventEx($arHandler, array(&$categories, $arParams['PATH_TO_CATEGORY']));
}
$arResult['CATEGORIES'] = $categories->GetItems();
sortByColumn($arResult['CATEGORIES'], "NAME");
//for pagination
$dbCatList = new CDBResult();
$dbCatList->InitFromArray($arResult['CATEGORIES']);
$arResult['CATEGORIES'] = array();
$dbCatList->NavStart($arParams['CATEGORY_COUNT'], false);
while ($arCat = $dbCatList->GetNext()) {
    $arResult['CATEGORIES'][strtolower($arCat["NAME"])] = $arCat;
}
$arResult['DB_LIST'] =& $dbCatList;
$arCatName = $categories->getItemsNames();
$arCatNameExists = array();
if (!empty($arCatName)) {
    // checking the category on the "red link"
    $arFilter = array('IBLOCK_ID' => $arParams['IBLOCK_ID'], 'CHECK_PERMISSIONS' => 'N', 'ACTIVE' => 'Y', 'NAME' => $arCatName);
    if (CWikiSocnet::IsSocNet()) {
        $arFilter['SUBSECTION'] = CWikiSocnet::$iCatId;
    }
    $rsElement = CIBlockElement::GetList(array(), $arFilter, false, false, array());
    while ($arElement = $rsElement->GetNext()) {
        $arCatNameExists[] = substr($arElement['NAME'], strpos($arElement['NAME'], ':') + 1);
    }
开发者ID:Satariall,项目名称:izurit,代码行数:31,代码来源:component.php

示例8: data

 /**
  * Обработчик результат. Вносим изменения при необходимости
  * @param  CDBResult $rsItems Выборка основного массива элементов
  * @return array              Основной массив элементов
  */
 private function data($rsItems) {
     while ($item = $rsItems->GetNext()) {
         $items[] = $this->composeItem(new Item($item));
     }
     return $items;
 }
开发者ID:ASDAFF,项目名称:stex,代码行数:11,代码来源:class.php

示例9: while

                while ($arRequest = $dbRequests->GetNext()) {
                    $gu = CComponentEngine::MakePathFromTemplate($arParams["PATH_TO_GROUP"], array("group_id" => $arRequest["GROUP_ID"]));
                    $arGroup = CSocNetGroup::GetByID($arRequest["GROUP_ID"]);
                    $arImage = array();
                    if (intval($arParams["THUMBNAIL_LIST_SIZE"]) > 0) {
                        if (intval($arGroup["IMAGE_ID"]) <= 0) {
                            $arGroup["IMAGE_ID"] = COption::GetOptionInt("socialnetwork", "default_group_picture", false, SITE_ID);
                        }
                        $arImage = CFile::ResizeImageGet($arGroup["IMAGE_ID"], array("width" => $arParams["THUMBNAIL_LIST_SIZE"], "height" => $arParams["THUMBNAIL_LIST_SIZE"]), BX_RESIZE_IMAGE_EXACT, false);
                    }
                    $arEventTmp = array("EVENT_TYPE" => "INVITE_GROUP", "ID" => $arRequest["ID"], "USER_ID" => $arRequest["USER_ID"], "GROUP_ID" => $arRequest["GROUP_ID"], "GROUP_URL" => $gu, "GROUP_NAME" => $arGroup["NAME"], "GROUP_IMG" => $arImage, "DATE_CREATE" => $arRequest["DATE_CREATE"], "MESSAGE" => $parser->convert($arRequest["~MESSAGE"], false, array(), array("HTML" => "N", "ANCHOR" => "Y", "BIU" => "Y", "IMG" => "Y", "LIST" => "Y", "QUOTE" => "Y", "CODE" => "Y", "FONT" => "Y", "SMILES" => "Y", "UPLOAD" => "N", "NL2BR" => "N")));
                    $arTmpResult["RequestsOut"][] = $arEventTmp;
                }
            }
            $rsRequestsOut = new CDBResult();
            $rsRequestsOut->InitFromArray($arTmpResult["RequestsOut"]);
            $rsRequestsOut->NavStart();
            while ($arRecord = $rsRequestsOut->GetNext()) {
                $arResult["RequestsOut"]["List"][] = $arRecord;
            }
            $arResult["RequestsOut"]["NAV_STRING"] = $rsRequestsOut->GetPageNavStringEx($navComponentObject, GetMessage("SONET_URE_NAV"), "", false);
        } else {
            $arResult["FatalError"] = GetMessage("SONET_URE_NO_PERMS");
        }
    } else {
        $arResult["FatalError"] = GetMessage("SONET_URE_NO_USER");
    }
    $arResult["InfoMessage"] = $infoMessage;
    $arResult["ErrorMessage"] = $errorMessage;
}
$this->IncludeComponentTemplate();
开发者ID:k-kalashnikov,项目名称:geekcon_new,代码行数:31,代码来源:component.php

示例10: GetNext

 function GetNext($bTextHtmlAuto = true, $use_tilda = true)
 {
     $r = parent::GetNext($bTextHtmlAuto, $use_tilda);
     if ($r) {
         $r["VALUE"] = $r["NAME"];
     }
     return $r;
 }
开发者ID:DarneoStudio,项目名称:bitrix,代码行数:8,代码来源:usertypeelement.php

示例11: BeonoYandexFotki

	"bShowAll" => $arParams["PAGER_SHOW_ALL"],
);
$arNavigation = CDBResult::GetNavParams($arNavParams);
	
try {
	$obAuthor = new BeonoYandexFotki($arParams["AUTHOR"], $arParams['CACHE_TIME']);
	$arRawResult = $obAuthor->getAlbumPhotos($arParams["ALBUM_ID"], array('sort' => $arParams['PHOTOS_SORT']));
	$arResult = $arRawResult;
	$arResult['ITEMS'] = array();
	
	if (is_array($arRawResult['ITEMS'])) {
		$dbresult = new CDBResult;
		$dbresult->InitFromArray($arRawResult['ITEMS']);
		$dbresult->NavStart($arParams['ITEMS_LIMIT'], false);	
		
		while ($arItem = $dbresult->GetNext()) {
			$arItem['URL'] = str_replace(array('#album_id#', '#photo_id#'), array($arParams["ALBUM_ID"], $arItem["ID"]), $arParams['PHOTO_URL']);
			$arResult['ITEMS'][] = $arItem;
		}			
				
		$arResult['PAGE_NUMBER'] = $dbresult->NavPageNomer;
		$arResult["NAV_STRING"] = $dbresult->GetPageNavStringEx($navComponentObject, false, $arParams["PAGER_TEMPLATE"], $arParams["PAGER_SHOW_ALWAYS"]);
	}
	
	if (!$arRawResult['ID']) {
		throw new Exception(GetMessage('BEONO_YAFOTKI_COMP_ERROR_ALBUM404'));
	}	
	
} catch (Exception $e) {
	ShowError($e->getMessage());
	$this->AbortResultCache();
开发者ID:ASDAFF,项目名称:bitrix-yandexfotki,代码行数:31,代码来源:component.php

示例12: CDBResult

unset($rsProduct, $arProductRow);
//$obRes = CCrmProduct::GetList($arResult['SORT'], $arFilter, $arSelect, $arNavParams);
$obRes = new CDBResult();
$obRes->InitFromArray($arResultData);
$obRes->NavStart($arNavParams);
$arResult['PRODUCTS'] = array();
//$arResult['PRODUCT_ID_ARY'] = array();
$arResult['PERMS']['ADD'] = true;
//!$CCrmProduct->cPerms->HavePerm('CONTACT', BX_CRM_PERM_NONE, 'ADD');
$arResult['PERMS']['WRITE'] = true;
//!$CCrmProduct->cPerms->HavePerm('CONTACT', BX_CRM_PERM_NONE, 'WRITE');
$arResult['PERMS']['DELETE'] = true;
//!$CCrmProduct->cPerms->HavePerm('CONTACT', BX_CRM_PERM_NONE, 'DELETE');
$arProductId = array();
$arPropertyValues = array();
while ($arElement = $obRes->GetNext()) {
    if ($arElement['TYPE'] === 'S') {
        $arElement['DELETE'] = $arElement['EDIT'] = true;
        $arResult['SECTIONS'][$arElement['ID']] = $arElement;
    } else {
        if ($arElement['TYPE'] === 'P') {
            //$CCrmProduct->cPerms->CheckEnityAccess('PRODUCT', 'WRITE', $arContactAttr[$arElement['ID']])
            //$CCrmProduct->cPerms->CheckEnityAccess('PRODUCT', 'DELETE', $arContactAttr[$arElement['ID']])
            $arElement['DELETE'] = $arElement['EDIT'] = true;
            $arElement['PATH_TO_PRODUCT_SHOW'] = CComponentEngine::MakePathFromTemplate($arParams['PATH_TO_PRODUCT_SHOW'], array('product_id' => $arElement['ID']));
            $arElement['PATH_TO_PRODUCT_EDIT'] = CComponentEngine::MakePathFromTemplate($arParams['PATH_TO_PRODUCT_EDIT'], array('product_id' => $arElement['ID']));
            $arElement['PATH_TO_PRODUCT_DELETE'] = CHTTP::urlAddParams(CComponentEngine::MakePathFromTemplate($arParams['PATH_TO_PRODUCT_LIST'], array('section_id' => $sectionID)), array('action_' . $arResult['GRID_ID'] => 'delete', 'ID' => $arElement['TYPE'] . $arElement['ID'], 'sessid' => bitrix_sessid()));
            foreach ($arPricesSelect as $fieldName) {
                $arElement['~' . $fieldName] = $arElement[$fieldName] = null;
            }
            foreach ($arVatsSelect as $fieldName) {
开发者ID:mrdeadmouse,项目名称:u136006,代码行数:31,代码来源:component.php


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