This file contains hidden or 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
// Native selectors. | |
(function(window, document) { | |
'use strict'; | |
var noop = function() { | |
}; | |
// DOCUMENT LOAD EVENTS | |
// not needed at the bottom of the page | |
document.addEventListener('DOMContentLoaded', noop); |
This file contains hidden or 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 | |
switch ($modx->event->name){ | |
case 'msOnBeforeAddToCart': | |
if (!is_array($options)) $options = json_decode($options, true); | |
//$modx->log(modX::LOG_LEVEL_ERROR, print_r($cart->get(), true)); | |
//$modx->log(modX::LOG_LEVEL_ERROR, print_r($product->toArray(), true)); | |
if(isset($options['size-price']) && !empty($options['size-price'])){ | |
$tvr = $modx->getObject('modTemplateVarResource', array( |
OlderNewer