Bitrix-D7 23.9
 
Загрузка...
Поиск...
Не найдено
application.php
1<?php
10
11use Bitrix\Main;
12
14{
15 protected $validUrls = array();
16
17 public function __construct()
18 {
19 }
20
26 public function checkScope()
27 {
29 $request = Main\Context::getCurrent()->getRequest();
30 $realPath = $request->getScriptFile();
31
32 foreach($this->validUrls as $url)
33 {
34 if(mb_strpos($realPath, $url) === 0)
35 {
36 return true;
37 }
38 }
39
40 return false;
41 }
42}