Exemplo n.º 1
0
        echo ShowError(GetMessage("T_NEWS_INDEX_MODULE_NA"));
    } else {
        //if(!CModule::IncludeModule("iblock")):
        $iblocks = GetIBlockList($IBLOCK_TYPE, array(), array(), $IBLOCK_SORT);
        while ($arIBlock = $iblocks->GetNext()) {
            ?>
			<font class="text">
			<a href="<?php 
            echo $arIBlock["LIST_PAGE_URL"];
            ?>
"><b><?php 
            echo $arIBlock["NAME"];
            ?>
</b></a><br><br></font>
			<?php 
            $items = GetIBlockElementList($arIBlock["ID"], false, $SORT, $NEWS_COUNT);
            ?>
			<table cellpadding="2" cellspacing="0" border="0" width="80%">
				<?php 
            while ($obItem = $items->GetNextElement()) {
                ?>
					<tr>
						<td width="100%">
							<?php 
                $arItem = $obItem->GetFields();
                $arProps = $obItem->GetProperties();
                $arLinkProp = $arProps["DOC_LINK"];
                ?>
							<font class="newsdata"><?php 
                echo $arItem["ACTIVE_FROM"];
                ?>
Exemplo n.º 2
0
    $APPLICATION->AddChainItem($vars["NAME"]);
    if ($bDisplayPanel && CModule::IncludeModule("iblock")) {
        CIBlock::ShowPanel($ID, 0, 0, $vars["IBLOCK_TYPE_ID"]);
    }
    $cache->Output();
} else {
    if (CModule::IncludeModule("iblock") && ($arIBlock = GetIBlock($ID, $IBLOCK_TYPE))) {
        if ($bPageTitle) {
            $APPLICATION->SetTitle($arIBlock["NAME"]);
        }
        $APPLICATION->AddChainItem($arIBlock["NAME"]);
        if ($bDisplayPanel) {
            CIBlock::ShowPanel($ID, 0, 0, $arIBlock["IBLOCK_TYPE_ID"]);
        }
        $cache->StartDataCache();
        $items = GetIBlockElementList($ID, false, $SORT, $NEWS_COUNT);
        $items->NavPrint(GetMessage("T_NEWS_NEWS_NAVIG"));
        ?>
<table cellpadding="0" cellspacing="10" border="0"><?php 
        while ($obItem = $items->GetNextElement()) {
            $arItem = $obItem->GetFields();
            //$arProp = $obItem->GetProperties();
            ?>
			<tr><td>
			<font class="text">
				<?php 
            if ($bDisplayPreviewPicture) {
                ?>
					<?php 
                echo ShowImage($arItem["PREVIEW_PICTURE"], 100, 100, "hspace='5' vspace='5' align='left' border='0'", $arItem["DETAIL_PAGE_URL"]);
                ?>
Exemplo n.º 3
0
    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);
        $items->NavPrint(GetMessage("T_NEWS_NEWS_NAVIG"));
        ?>
<table cellpadding="0" cellspacing="10" border="0"><?php 
        while ($obItem = $items->GetNextElement()) {
            $arItem = $obItem->GetFields();
            $arProp = $obItem->GetProperties();
            if (strlen(trim($DETAIL_PAGE_URL)) > 0) {
                $ItemDetailPageURL = CIBlock::ReplaceDetailUrl($DETAIL_PAGE_URL, $arItem, true);
            } else {
                $ItemDetailPageURL = $arItem["DETAIL_PAGE_URL"];
            }
            ?>
			<tr><td>
			<font class="text">
				<?php 
Exemplo n.º 4
0
            CIBlock::ShowPanel($IBLOCK_ID, $ELEMENT_ID, $SECTION_ID, $IBLOCK_TYPE);
        }
        $APPLICATION->SetTitle($ELEMENT_NAME);
        if (is_array($arrPath)) {
            while (list($key, $arS) = each($arrPath)) {
                if ($SECTION_ID == $arS["ID"]) {
                    $SECTION_NAME = $arS["NAME"];
                }
                $APPLICATION->AddChainItem($arS["NAME"], $SECTION_URL . "&SECTION_ID=" . $arS["ID"]);
            }
        }
        CIBlockElement::CounterInc($ELEMENT_ID);
        if ($obCache->StartDataCache()) {
            // get the values for the Next and Previous links
            $arSelect = array("ID", "IBLOCK_ID", "IBLOCK_SECTION_ID", "DETAIL_PAGE_URL");
            if ($rs = GetIBlockElementList($IBLOCK_ID, $SECTION_ID, array($ELEMENT_SORT_FIELD => $ELEMENT_SORT_ORDER, "ID" => "ASC"), 0, array("ACTIVE" => "Y"), $arSelect)) {
                while ($ar = $rs->GetNext()) {
                    if ($end == "Y") {
                        $next_url = $ar["DETAIL_PAGE_URL"];
                        break;
                    }
                    if ($ar["ID"] == $ELEMENT_ID) {
                        $end = "Y";
                    } else {
                        $prev_url = $ar["DETAIL_PAGE_URL"];
                    }
                }
            }
            ?>
<p><font class="smalltext"><?php 
            if (strlen($prev_url) > 0) {