Search code examples
bitrix

Bitrix - Can I change $arResult array from a file where it is created


I am working on some changes in CRM > Deal section. I want to make some changes in $arresult[] array for some form validation. It takes a ready made input tag in field array. But I want to know in which file this variable $arresult[] is created?

Any help will be appreciated.


Solution

  • $arResult is created in the corresponding component. In your case it would be crm.deal.edit or crm.deal.list. These system components are located in /bitrix/components/bitrix/.

    You should not modify "core" components anyway. If you want to somehow modify $arResult either create your own component (copy to /bitrix/components/YOUR_NAMESPACE/ or use result_modifier.php in the component's template.