Views: 9302
Last Modified: 19.09.2014

Cannot Find Component Access Code

This error is quite common when you try to edit component parameters in the page editing mode. Although the code contains the line $APPLICATION->IncludeComponent() (component access), sometimes the error Cannot find component access code appears anyway. Unfortunately, there is no one-size-fits-all solution for this problem.

Possible solutions:

  • Include two strings to .htaccess:

    For non-UTF:

        php_value mbstring.func_overload 0
        php_value mbstring.internal_encoding latin1

    For UTF:

        php_value mbstring.func_overload 2
        php_value mbstring.internal_encoding UTF-8
  • The error possibly appears due to the incorrect placement of html tags (e.g., one of the tags is closed in a wrong place);
  • Remove all of the html comments from the page;
  • Frame the component access code with the symbols <? ?> (thus separating it from another php code);
  • Place the structure <?/**/?> before component access;
  • Remove several similar components close to the component that fails to work.


Courses developed by Bitrix24