<?
	header("Content-Type: text/html; charset=utf-8");
	
	$g_path = '../../my/';
	
	include $g_path."u_globals.php";
	include $g_path."html/f.php";
	include $g_path."u_spoj_na_bazu.php";
	
	include $g_path."u_headers.php";
	
	
	$x = get_data('select ncp, price, tax_group_id from products where id = "'.$_GET['value'].'" ', 0);
	
	$y = get_data('select tax_1, tax_2 from tax_groups where id = "'.$x['tax_group_id'].'" ', 0);
	
	//p($x);
	//p($y);
	
	/*
	$y = get_item('select value from settings where name = "duty.free" ');
	if($y == 'yes'){
		$l_pdv = get_item('select tax_1 from tax_groups where id = "'.$x['tax_group_id'].'" ');
	}else{
		$l_pdv = 0;
	}
	*/
	
	
	$la_data[0] = $x['ncp'];
	$la_data[1] = $x['price'];
	$la_data[2] = $y['tax_1'];
	$la_data[3] = $y['tax_2'];
	
	$la_json = json_encode($la_data);
	print $la_json;
?>
