			var price_with_options_ajax_call = function() {
			const mainPhoto = document.getElementById('main-img');
				$.ajax({
					type: 'POST',
					url: 'index.php?route=product/live_options/index&product_id=68082',
					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) {
							$('.product-price-3').text(json.new_price.no_tax);
							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(json.new_price.special) {
								if ($('#content .price-new-live').length <= 0) {
									//Add old price, crossed over
									$('.product-price-2').after('<div class="product-price-1 price-old-live">'+json.new_price.price+'</div>').fadeIn(250);
									//Change class for price
									$('.product-price-2 .price-old-live').removeClass('price-old-live').addClass('price-new-live');
								}
								
								//Insert regular price
								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);
									animation_on_change_price_with_options('#stock_qty', json.qty_in_stock);	
								}
							}else{
								if ($('#content .price-new-live').length > 0) {
									//Clear the old price container, but leave the HTML element and classes
									$('#content .price-old-live').text('').fadeOut(250);

									//Insert regular price into special price container, since it exists, but there's no special price
									if (json.new_price.price) {
										animation_on_change_price_with_options('#content .price-new-live', json.new_price.price);
									}
								}else{
									//Insert regular price
									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);
									}									
								}
							}
						
							//special price
							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);
							}

							// 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);
							}
							
							animation_on_change_price_with_options('#stock_qty', json.qty_in_stock);
								animation_on_change_price_with_options('#option_id', json.id);
								animation_on_change_price_with_options('#model', json.model);
								
								const mainImg = mainPhoto.querySelector('.img-responsive');
            					mainImg.src = json.option_image;
            
            					const zoomImg = mainPhoto.querySelector('.zoomImg');
            					if (zoomImg) {
             						zoomImg.src = json.option_image;
             					}
						}
					},
					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=\'hidden\'], #content input[type=\'radio\']:checked, #content input[type=\'checkbox\'], #content select, #content textarea', 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);
				});
			}