<?$arText = explode('#MY_COMPONENT#',$arResult['DETAIL_TEXT']); for($i=0;$i<count($arText);$i++) { echo $arText[$i]; if ($i>0) $APPLICATION->IncludeComponent('my:my_component',''); }?>