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 | |
$installPackages = array( | |
'sdStore' | |
, 'translit' | |
, 'SanitizeUpload' | |
, 'TinyMCE' | |
, 'FormIt' | |
, 'Analytics' | |
, 'Big Brother' |
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 | |
/** @var modX $modx */ | |
/** @var array $scriptProperties */ | |
/** @var miniShop2 $miniShop2 */ | |
$miniShop2 = $modx->getService('miniShop2'); | |
$miniShop2->initialize($modx->context->key); | |
/** @var pdoFetch $pdoFetch */ | |
if (!$modx->loadClass('pdofetch', MODX_CORE_PATH . 'components/pdotools/model/pdotools/', false, true)) { | |
return false; | |
} |
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 | |
/** @var modX $modx */ | |
/** @var array $scriptProperties */ | |
/** @var miniShop2 $miniShop2 */ | |
$miniShop2 = $modx->getService('miniShop2'); | |
$miniShop2->initialize($modx->context->key); | |
/** @var pdoFetch $pdoFetch */ | |
if (!$modx->loadClass('pdofetch', MODX_CORE_PATH . 'components/pdotools/model/pdotools/', false, true)) { | |
return false; | |
} |
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
{'!pdoResources' | snippet: [ | |
'parents' => 53, | |
'limit' => 10, | |
'includeTVs' => 'eventDate, eventImage, eventPrice', | |
'depth' => 5, | |
'sortby' => 'eventDate', | |
'sortdir' => 'ASC', | |
'tvPrefix' => '', | |
'tpl' => '@FILE tpl/latestEvent.tpl', | |
'showLog' => 0, |
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
function preloader(show) { | |
var template = '<div class="preloader" style="position: fixed;width: 100%;height: 100%;background: rgba(255,255,255,0.45);top: 0;left: 0;z-index: 99999;display: flex;justify-content: center;align-items: center;"><img src="preloader.svg"><div>'; | |
if (show) { | |
$(template).appendTo('body'); | |
return; | |
} | |
$(document).find('.preloader').remove(); | |
} |
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
{'!pdoResources' | snippet: [ | |
'class' => 'RvgVideos', | |
'sortby' => 'rank', | |
'limit' => 0, | |
'tpl' => '@FILE pdo/videoItem.tpl' | |
]} |
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 \Psr\Http\Message\ServerRequestInterface as Request; | |
use \Psr\Http\Message\ResponseInterface as Response; | |
require '........../autoload.php'; // путь к композеру | |
define('MODX_API_MODE', true); | |
require $_SERVER["DOCUMENT_ROOT"].'/index.php'; |
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
[[!pdoPage? | |
&element=`pdoResources` | |
&parents=`4, 12, 17, 27` | |
&depth=`5` | |
&tpl=`list_material_tpl_view` | |
&includeTVs=`image,views` | |
&where=`modResource.isfolder IS NOT UNKNOWN AND DATE(FROM_UNIXTIME(modResource.publishedon)) > DATE_SUB(NOW(), INTERVAL 1 MONTH)` | |
&limit=`12` | |
&sortby=`{"CAST(views AS DECIMAL(13,3))":"DESC"}` | |
&tvPrefix=`` |
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 | |
/** @var modX $modx */ | |
switch ($modx->event->name) { | |
case 'pdoToolsOnFenomInit': | |
$fenom->addModifier('round', function ($input) { | |
return round($input,1); | |
}); | |
$fenom->addModifier('format_price', function ($input) { |
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
$(document).on('pdopage_load', function(e, config, response) { | |
// masonry media | |
var $masonryContainer = $('.media__block_masonry'); | |
if ($masonryContainer.length) { | |
$masonryContainer.masonry({ | |
itemSelector: '.media__item', | |
gutter: '.media__gutter', | |
horizontalOrder: true | |
}); | |
$masonryContainer.masonry( 'reloadItems' ); |
OlderNewer