<code lang="php">
if (substr(php_sapi_name(), 0, 3) !== 'cli') {
die();
}
define('NO_KEEP_STATISTIC', true);
define('NO_AGENT_CHECK', true);
if (empty($_SERVER['DOCUMENT_ROOT'])) {
$_SERVER['DOCUMENT_ROOT'] = realpath(dirname(__FILE__) . '/../');
}
require($_SERVER['DOCUMENT_ROOT'] . '/bitrix/modules/main/include/prolog_before.php');
тут код который надо выполнить
require($_SERVER['DOCUMENT_ROOT'] . '/bitrix/modules/main/include/epilog_after.php');
</code>
<tr>
<th>Оборудование для интернета</th>
<th>Покупка</th>
<th>Аренда</th>
<th>Рассрочка</th>
</tr>
<tr>
<?foreach($arResult["ITEMS"] as $arItem):?>
<th><?=$arItem["NAME"]?></th>
<th><?=$arItem["DISPLAY_PROPERTIES"]["PURCHASE"]["VALUE"]?></th>
<th><?=$arItem["DISPLAY_PROPERTIES"]["HIRE"]["VALUE"]?></th>
<th><?=$arItem["DISPLAY_PROPERTIES"]["TIME_PLAN"]["VALUE"]?></th>
<?endforeach;?>
</tr>
<tr>
<th>Оборудование для интернета</th>
<th><?=$arResult["ITEMS"][0]["DISPLAY_PROPERTIES"]["PURCHASE"]["NAME"]?></th>
<th><?=$arResult["ITEMS"][0]["DISPLAY_PROPERTIES"]["HIRE"]["NAME"]?></th>
<th><?=$arResult["ITEMS"][0]["DISPLAY_PROPERTIES"]["TIME_PLAN"]["NAME"]?></th>
</tr>
while ($row = $results->Fetch())
{
echo $row['NAME'];//выводим все значения, которые вернул запрос
}