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
<div class="row ms2_product"> | |
<div class="col-md-8"> | |
<form method="post" class="ms2_form"> | |
<a href="{$rid | url}">{$product_pagetitle}</a> | |
{if $_pls['120x90']?} | |
<img src="{$_pls['120x90']}" alt="{$product_pagetitle}" title="{$product_pagetitle}"/> | |
{else} | |
<img src="{'assets_url' | option}components/minishop2/img/web/ms2_small.png" | |
srcset="{'assets_url' | option}components/minishop2/img/web/ms2_small@2x.png 2x" |
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 array $scriptProperties */ | |
/* @var payandsee $payandsee */ | |
if (!function_exists('explodeAndClean')) { | |
function explodeAndClean($array, $delimiter = ',') | |
{ | |
$array = explode($delimiter, $array); // Explode fields to array | |
$array = array_map('trim', $array); // Trim array's values |
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
{$_modx->lexicon->load('minishop2:product')} | |
<div id="msCart"> | |
{if !count($products)} | |
{'ms2_cart_is_empty' | lexicon} | |
{else} | |
<div class="table-responsive"> | |
<table class="table table-striped"> | |
<tr class="header"> | |
<th class="image"> </th> |
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
``` | |
[[msOptionsColor? | |
&product=`[[*id]]` | |
&name=`color` | |
&tplRow=`_msOptionsColor.row` | |
&tplOuter=`_msOptionsColor.outer` | |
&active=`1` | |
]] | |
``` |
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 | |
$corePath = $modx->getOption('userfiles_core_path', null, | |
$modx->getOption('core_path', null, MODX_CORE_PATH) . 'components/userfiles/'); | |
/** @var UserFiles $UserFiles */ | |
$UserFiles = $modx->getService( | |
'userfiles', | |
'userfiles', | |
$corePath . 'model/userfiles/', |
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 $cost */ | |
/** @var $options */ | |
/** @var $modifications array */ | |
switch ($modx->event->name) { | |
case 'msopOnGetFullCost': | |
if (!$msoptionsprice = $modx->getService('msoptionsprice') | |
) { | |
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
{foreach $options as $name => $values} | |
<div class="sm-text"><b>{('ms2_product_' ~ $name) | lexicon}</b></div> | |
{foreach $values as $value index=$index} | |
<label> | |
<input type="radio" value="{$values[$index]}" name="options[{$name}]" {if $index == 0}checked="checked"{/if}/> | |
{$values[$index]} |
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
/** v 1.1.0 */ | |
var quickview = { | |
config: {}, | |
defaults: { | |
selectors: { | |
view: 'quickview-view', | |
close: 'quickview-close btn-danger', | |
next: 'quickview-next btn-info', | |
prev: 'quickview-prev btn-info' |
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
<h1>[[*pagetitle]]</h1> | |
<div id="msProduct" class="row"> | |
<div class="col-md-6"> | |
[[!msGallery]] | |
</div> | |
<div class="col-md-6"> | |
<form class="form-horizontal ms2_form msoptionsprice-product" method="post"> | |
<input type="hidden" name="id" value="[[*id]]"/> | |
<div class="form-group"> | |
<label class="col-md-2 control-label">[[%ms2_product_article]]:</label> |