This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var ajaxFormSubmit = function (form, event) { | |
var string = $(form).serialize(); | |
$.ajax({ | |
type: "POST", | |
url: "/local/templates/chistikov/assets/libs/php/mail.php", | |
data: string, | |
success: function(html) { | |
$("#answer").html(html); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if (!\Bitrix\Main\Loader::includeModule('iblock')) | |
{ | |
ShowError(Loc::getMessage('IBLOCK_MODULE_NOT_INSTALLED')); | |
return; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<meta http-equiv="Content-Type" content="text/html; charset=<?= LANG_CHARSET;?>" /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Push in end value in associative array. | |
* Добавляет в конец значение в ассоциативный массив. | |
* @return array | |
*/ | |
function array_push_associative($array, $key, $value) | |
{ | |
$array[$key] = $value; | |
return $array; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Получить все торговые предложения. | |
* | |
* Get all SKU's properties | |
* | |
* @return array | |
*/ | |
<?php | |
use Bitrix\Main\Loader; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$modulePath = 'Modules\\' . env('CURRENT_MODULE'); | |
$moduleNamespace = 'Modules\\'. env('CURRENT_MODULE'). '\\'; | |
return [ | |
/* | |
|-------------------------------------------------------------------------- | |
| Paths |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
return [ | |
/* | |
|-------------------------------------------------------------------------- | |
| Module Namespace | |
|-------------------------------------------------------------------------- | |
| | |
| Default module namespace. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<? | |
$cacheId = 'flowersSKU'; | |
$cacheTtl = '604800000'; // 7 дней срок в миллисекундах. | |
$cache = \Bitrix\Main\Application::getInstance()->getManagedCache(); | |
/*** | |
* Проверка на наличие слуществующего кэша с таким ID, | |
* если есть, то записываем в переменную $resOffers, | |
* иначе cохраняем результат функции в кэш. | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
use Bitrix\Main\Application; | |
use Bitrix\Main\Diag\Debug; | |
use Bitrix\Main\Loader; | |
use Bitrix\Main\LoaderException; | |
$request = Application::getInstance()->getContext()->getRequest(); | |
function is_ajax() | |
{ |
OlderNewer