Vinoteca: wine shop on 1C-Bitrix (module, template, components, pages)

This commit is contained in:
jimagie committed 2026-10-22 23:22:27 +05:00
commit 52795535ae
586 files changed
+27619

No files matched your search

@@ -0,0 +1,17 @@
<?php
declare(strict_types=1);
namespace Jinove\Vinoteca;
use Bitrix\Main\HttpRequest;
class Origin
{
public static function allowed(HttpRequest $request): bool
{
$origin = (string)($request->getHeader("Origin") ?? "");
return $origin === "" || $origin === Config::host();
}
}