/* date */ if(in_array($prop['CODE'], array('creation_date', 'edit_date'))) $prop['VALUE'] = date(GetMessage("PR_RECRM_C_DATE"), $prop['VALUE']); /* datetime */ if(in_array($prop['CODE'], array('creation_datetime', 'edit_datetime'))) $prop['VALUE'] = date(GetMessage("PR_RECRM_C_DATETIME"), $prop['VALUE']); $arItem['PROPERTIES_RECRM'][$prop['CODE']] = $prop; endif; } $arResult = $arItem; $arResult["IBLOCK"] = GetIBlock($arResult["IBLOCK_ID"], $arResult["IBLOCK_TYPE"]); $arResult["SECTION"] = array("PATH" => array()); $arResult["SECTION_URL"] = ""; $this->SetResultCacheKeys(array( "ID", "IBLOCK_ID", "NAV_CACHED_DATA", "NAME", "IBLOCK_SECTION_ID", "IBLOCK", "LIST_PAGE_URL", "~LIST_PAGE_URL", "SECTION_URL", "SECTION", "PROPERTIES", "IPROPERTY_VALUES",
/** * Returns an array with section fields if found. Else returns false. * * @param int $ID * @param string $TYPE * * @return array|bool * @deprecated No longer used by internal code and not recommended. */ function GetIBlockSection($ID, $TYPE = "") { $ID = intval($ID); if ($ID > 0) { $iblockSection = CIBlockSection::GetList(array(), array("ID" => $ID, "ACTIVE" => "Y")); if ($arIBlockSection = $iblockSection->GetNext()) { if ($arIBlock = GetIBlock($arIBlockSection["IBLOCK_ID"], $TYPE)) { $arIBlockSection["IBLOCK_ID"] = $arIBlock["ID"]; $arIBlockSection["IBLOCK_NAME"] = $arIBlock["NAME"]; return $arIBlockSection; } } } return false; }
<?php if (!defined("B_PROLOG_INCLUDED") || B_PROLOG_INCLUDED !== true) { die; } $APPLICATION->IncludeComponent("bitrix:catalog.section.list", "", array("IBLOCK_TYPE" => $arParams["IBLOCK_TYPE"], "IBLOCK_ID" => $arParams["IBLOCK_ID"], "DISPLAY_PANEL" => $arParams["DISPLAY_PANEL"], "CACHE_TYPE" => $arParams["CACHE_TYPE"], "CACHE_TIME" => $arParams["CACHE_TIME"], "CACHE_GROUPS" => $arParams["CACHE_GROUPS"], "SECTION_URL" => $arResult["FOLDER"] . $arResult["URL_TEMPLATES"]["section"]), $component); if (CModule::IncludeModule("iblock") && ($arIBlock = GetIBlock($arParams['IBLOCK_ID'], $arParams['~IBLOCK_TYPE']))) { ?> <div class="sect_text sect_catalog clearfix"> <?php //trace($arIBlock); ?> <?php if ($arIBlock['PICTURE']) { ?> <?php $rsFile = CFile::GetByID($arIBlock['PICTURE']); $arFile = $rsFile->Fetch(); //trace($arFile); ?> <img class="iblock-pic" src="/upload/<?php echo $arFile['SUBDIR']; ?> /<?php echo $arFile['FILE_NAME']; ?> " alt="<?php echo $arIBlock['NAME']; ?> " /> <?php
$APPLICATION->SetTitle(GetMessage("T_NEWS_NEWS_TITLE")); $cache = new CPHPCache(); if ($cache->InitCache($CACHE_TIME, $CACHE_ID)) { $vars = $cache->GetVars(); $APPLICATION->SetTitle($vars["NAME"]); if ($INCLUDE_IBLOCK_INTO_CHAIN == "Y") { $APPLICATION->AddChainItem($vars["NAME"]); } if (CModule::IncludeModule("iblock")) { if ($bDisplayPanel) { CIBlock::ShowPanel($ID, 0, $SECTION_ID, $vars["IBLOCK_TYPE_ID"]); } } $cache->Output(); } else { if (CModule::IncludeModule("iblock") && ($arIBlock = GetIBlock($ID, $IBLOCK_TYPE))) { if (IntVal($SECTION_ID) > 0 && ($arSection = GetIBlockSection($SECTION_ID, $arIBlock["IBLOCK_TYPE_ID"]))) { $PageTitle = $arSection["NAME"]; } else { $PageTitle = $arIBlock["NAME"]; } $APPLICATION->SetTitle($PageTitle); if ($INCLUDE_IBLOCK_INTO_CHAIN == "Y") { $APPLICATION->AddChainItem($PageTitle); } if ($bDisplayPanel) { CIBlock::ShowPanel($ID, 0, $SECTION_ID, $arIBlock["IBLOCK_TYPE_ID"]); } $cache->StartDataCache(); $arSelect = array("ID", "DETAIL_PAGE_URL", "PREVIEW_PICTURE", "DATE_ACTIVE_FROM", "NAME", "PREVIEW_TEXT", "PREVIEW_TEXT_TYPE", "PROPERTY_*"); $items = GetIBlockElementList($ID, $SECTION_ID, $SORT, $NEWS_COUNT, $FILTER, $arSelect);
echo $ELEMENT_NAME; ?> </a></font></p> <?php if ($count > 0) { // element title from the information block type description, will be used for page navigation $arIblockType_link = CIBlockType::GetByIDLang($LINK_IBLOCK_TYPE, LANGUAGE_ID); $ELEMENT_LINK_NAME = $arIblockType_link["ELEMENT_NAME"]; ?> <p><?php echo $rsElements_link->NavPrint($LINK_ELEMENT_NAME); ?> </p><?php // information block of the linked elements if (!is_set($arIBlock_link, $LINK_IBLOCK_ID)) { $arIBlock_link[$LINK_IBLOCK_ID] = GetIBlock($LINK_IBLOCK_ID); } $obElement = $rsElements_link->GetNextElement(); $arElement = $obElement->GetFields(); $arProperty = $obElement->GetProperties(); ?> <table cellspacing=0 cellpadding=0 border=0 class="tableborder" width="100%"> <tr> <td width="100%"> <table cellspacing=1 cellpadding=5 border=0 width="100%"> <tr> <td class="tablehead"><font class="tableheadtext"><?php echo GetMessage("CATALOG_TITLE"); ?> </font></td> <?php