Answer the question
In order to leave comments, you need to log in
Error 403 (Forbidden), how to give access to php file for ajax?
When making an ajax request, throw an error:
POST https://test.ru/bitrix/modules/test/admin/ajax.php 403 (Forbidden)
BX.ajax.post('/bitrix/modules/<?=$module_id?>/admin/ajax.php',data,function(result){});
Satisfy any
order allow,deny
allow from all
Answer the question
In order to leave comments, you need to log in
Develop your own modules in the /local/modules folder, not in the /bitrix/modules folder.
In the ajax.php file, you are most likely connecting the Bitrix core, and you didn’t specify access to read the file at the level of Bitrix users or didn’t set a constant in the file so as not to check the rights (which is not safe in some cases).
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question