Warning: unlink(/home/mmtuning/storage_sub_new/cache/cache.ProductgetProducts217c35d5e096bb20cc94e8524014d7d5.1755789438): No such file or directory in /home/mmtuning/public_html/system/library/cache/file.php on line 20Warning: unlink(/home/mmtuning/storage_sub_new/cache/cache.ProductgetProducts23fee553b564333f8f982be46da6e573.1755789438): No such file or directory in /home/mmtuning/public_html/system/library/cache/file.php on line 20Warning: unlink(/home/mmtuning/storage_sub_new/cache/cache.ProductgetProducts284639bbc1e023c125dbee429cb0a89e.1755789438): No such file or directory in /home/mmtuning/public_html/system/library/cache/file.php on line 20Warning: unlink(/home/mmtuning/storage_sub_new/cache/cache.ProductgetProducts2fba3cb64a4ccad8f0a48bb49d459736.1755789438): No such file or directory in /home/mmtuning/public_html/system/library/cache/file.php on line 20Warning: unlink(/home/mmtuning/storage_sub_new/cache/cache.ProductgetProducts376a962a553ced7df42bee102bb9d96b.1755789438): No such file or directory in /home/mmtuning/public_html/system/library/cache/file.php on line 20Warning: unlink(/home/mmtuning/storage_sub_new/cache/cache.ProductgetProducts3fbea936aa174a8e859fe653a9a7868b.1755789438): No such file or directory in /home/mmtuning/public_html/system/library/cache/file.php on line 20Warning: unlink(/home/mmtuning/storage_sub_new/cache/cache.ProductgetProducts3fc0873c5bdb6b17f614daaeec492ea7.1755789438): No such file or directory in /home/mmtuning/public_html/system/library/cache/file.php on line 20Warning: unlink(/home/mmtuning/storage_sub_new/cache/cache.ProductgetProducts464b0b5e5d38d4f785e96a8f14e7884d.1755789438): No such file or directory in /home/mmtuning/public_html/system/library/cache/file.php on line 20Warning: unlink(/home/mmtuning/storage_sub_new/cache/cache.ProductgetProducts498780c06957ea98024ccb0255d676fe.1755789438): No such file or directory in /home/mmtuning/public_html/system/library/cache/file.php on line 20Warning: unlink(/home/mmtuning/storage_sub_new/cache/cache.ProductgetProducts4d00bfbbd3ac935c49b8c4d5df42d6be.1755789438): No such file or directory in /home/mmtuning/public_html/system/library/cache/file.php on line 20Warning: unlink(/home/mmtuning/storage_sub_new/cache/cache.ProductgetProducts5040ee6b6f3bbdcf36f915b8b3ab4200.1755789438): No such file or directory in /home/mmtuning/public_html/system/library/cache/file.php on line 20Warning: unlink(/home/mmtuning/storage_sub_new/cache/cache.ProductgetProducts54c4b867d7c8ca89dcd5a9b7bb7ca258.1755789438): No such file or directory in /home/mmtuning/public_html/system/library/cache/file.php on line 20Warning: unlink(/home/mmtuning/storage_sub_new/cache/cache.ProductgetProducts5614b4653495e90489ae2d7562ba8dc4.1755789438): No such file or directory in /home/mmtuning/public_html/system/library/cache/file.php on line 20Warning: unlink(/home/mmtuning/storage_sub_new/cache/cache.ProductgetProducts5d472e193f299026047eb815477da8bb.1755789438): No such file or directory in /home/mmtuning/public_html/system/library/cache/file.php on line 20Warning: unlink(/home/mmtuning/storage_sub_new/cache/cache.ProductgetProducts622b0e90c10906534fed3804deac732e.1755789438): No such file or directory in /home/mmtuning/public_html/system/library/cache/file.php on line 20Warning: unlink(/home/mmtuning/storage_sub_new/cache/cache.ProductgetProducts65e478801e5bc2d1df71a933e3ec779b.1755789438): No such file or directory in /home/mmtuning/public_html/system/library/cache/file.php on line 20Warning: unlink(/home/mmtuning/storage_sub_new/cache/cache.ProductgetProducts77f2b99781ce3b4a1ec073b36d755d84.1755789438): No such file or directory in /home/mmtuning/public_html/system/library/cache/file.php on line 20Warning: unlink(/home/mmtuning/storage_sub_new/cache/cache.ProductgetProducts7b41943cf8ddb521483baaeb77ac1197.1755789438): No such file or directory in /home/mmtuning/public_html/system/library/cache/file.php on line 20Warning: unlink(/home/mmtuning/storage_sub_new/cache/cache.ProductgetProducts9033326adc389854590f5a358e548e58.1755789438): No such file or directory in /home/mmtuning/public_html/system/library/cache/file.php on line 20Warning: unlink(/home/mmtuning/storage_sub_new/cache/cache.ProductgetProducts9370a8f60acc9ea68e724e26b06bee34.1755789438): No such file or directory in /home/mmtuning/public_html/system/library/cache/file.php on line 20Warning: unlink(/home/mmtuning/storage_sub_new/cache/cache.ProductgetProductsd9a8bae4606aa9e3f4906ca3a479da07.1755789438): No such file or directory in /home/mmtuning/public_html/system/library/cache/file.php on line 20Warning: unlink(/home/mmtuning/storage_sub_new/cache/cache.ProductgetProductsdd0d26d8de8a9f9e1cff608377d156a1.1755789438): No such file or directory in /home/mmtuning/public_html/system/library/cache/file.php on line 20Warning: Cannot modify header information - headers already sent by (output started at /home/mmtuning/public_html/system/framework.php:42) in /home/mmtuning/public_html/catalog/controller/startup/session.php on line 27Warning: Cannot modify header information - headers already sent by (output started at /home/mmtuning/public_html/system/framework.php:42) in /home/mmtuning/storage_sub_new/modification/catalog/controller/startup/startup.php on line 101Warning: Cannot modify header information - headers already sent by (output started at /home/mmtuning/public_html/system/framework.php:42) in /home/mmtuning/storage_sub_new/modification/catalog/controller/startup/startup.php on line 159 var price_with_options_ajax_call = function() {
$.ajax({
type: 'POST',
url: 'index.php?route=extension/module/live_options&product_id=2006',
data: $('#content input[type=\'text\'], #content input[type=\'number\'], #content input[type=\'hidden\'], #content input[type=\'radio\']:checked, #content input[type=\'checkbox\']:checked, #content select, #content textarea'),
dataType: 'json',
beforeSend: function() {
// you can add smth useful here
},
complete: function() {
// you can add smth useful here
},
success: function(json) {
if (json.success) {
if ($('#content .price-tax-live').length > 0 && json.new_price.tax) {
animation_on_change_price_with_options('#content .price-tax-live', json.new_price.tax);
}
if ($('#content .price-new-live').length > 0 && json.new_price.special) {
animation_on_change_price_with_options('#content .price-new-live', json.new_price.special);
}
if ($('#content .price-old-live').length > 0 && json.new_price.price) {
animation_on_change_price_with_options('#content .price-old-live', json.new_price.price);
}
// points
if ($('#content .spend-points-live').length > 0 && json.new_price.points) {
animation_on_change_price_with_options('#content .spend-points-live', json.new_price.points);
}
// reward
if ($('#content .get-reward-live').length > 0 && json.new_price.reward) {
animation_on_change_price_with_options('#content .get-reward-live', json.new_price.reward);
}
}
},
error: function(error) {
console.log('error: '+error);
}
});
}
var animation_on_change_price_with_options = function(selector_class_or_id, new_html_content) {
$(selector_class_or_id).fadeOut(150, function() {
$(this).html(new_html_content).fadeIn(50);
});
}
if ($('#content input[name=\'quantity\']').val() > 1)
{
price_with_options_ajax_call();
}
if ( jQuery.isFunction(jQuery.fn.on) )
{
$(document).on('change', '#content input[type=\'text\'], #content input[type=\'number\'], #content input[type=\'hidden\'], #content input[type=\'radio\']:checked, #content input[type=\'checkbox\'], #content select, #content textarea, #content input[name=\'quantity\']', function () {
price_with_options_ajax_call();
});
$(document).on('input', '#content input[type=\'text\'], #content input[type=\'number\'], #content input[name=\'quantity\']', function () {
price_with_options_ajax_call();
});
}
else
{
$('#content input[type=\'text\'], #content input[type=\'number\'], #content input[type=\'hidden\'], #content input[type=\'radio\']:checked, #content input[type=\'checkbox\'], #content select, #content textarea, #content input[name=\'quantity\']').live('change', function() {
price_with_options_ajax_call();
});
}
// Support spinner_quantity
if( $('.number-spinner button').length ){
$(document).on('click', '.number-spinner button', function () {
setTimeout(function() {
price_with_options_ajax_call();
}, 100);
});
}
// Support bt_claudine
if( $('.increase').length || $('.decrease').length ){
$(document).on('click', '.increase', function () {
setTimeout(function() {
price_with_options_ajax_call();
}, 100);
});
$(document).on('click', '.decrease', function () {
setTimeout(function() {
price_with_options_ajax_call();
}, 100);
});
}
// Support Pav theme
if( $('.quantity-adder .add-action').length ){
$(".quantity-adder .add-action").bind( "mouseup touchend", function(e){
setTimeout(function() {
price_with_options_ajax_call();
}, 100);
});
}
// Support vitalia
if( $('#q_up').length || $('#q_down').length ){
$('#q_up,#q_down').click(function(){
setTimeout(function() {
price_with_options_ajax_call();
}, 100);
});
}
// Support journal2
if( $('.qty .journal-stepper').length ){
$(".qty .journal-stepper").bind( "mouseup touchend", function(e){
setTimeout(function() {
price_with_options_ajax_call();
}, 100);
});
}