<?
	header("Content-Type: text/html; charset=utf-8");
	
	//$g_path = '../../my/';
	$la_tmp = explode('/app/', $_SERVER['SCRIPT_FILENAME']);
	
	$l_path_minus = $la_tmp[0].'/app/webroot/iso/';
	$g_path = $la_tmp[0].'/app/webroot/iso/my/';
	
	include $g_path."u_globals.php";
	include $g_path."html/f.php";
	include $g_path."u_spoj_na_bazu.php";
	
	$can_live_alone = 1;
	include $g_path."u_headers.php";
	include $g_path."u_log.php";
	
	
	$result = 0;
	
	
	$l_sql = 'delete from control_ns_details ';
	$rez = mysql_query($l_sql);
	
	if($rez){
		$result = 1;
	}else{
		$result = 0;
	}
	
	
	$l_sql = 'delete from control_ns';
	$rez = mysql_query($l_sql);
	
	if($rez && $result == 1){
		$result = 1;
	}else{
		$result = 0;
	}
	
	
	$la_data = array();
	$la_data['result'] = $result;
	
	$la_json = json_encode($la_data);
	print $la_json;
	exit;
?>