20 lines
611 B
PHP
20 lines
611 B
PHP
<?php
|
|
//tag listánál ez adja vissza a keresés eredményét
|
|
ini_set('include_path', '../_class/');
|
|
include('class_sql.php');
|
|
if ($_SERVER['HTTP_HOST'] == 'cegledcoach.hu') $sql = new sql('cegled_mysql','root','','badminton_coach');
|
|
else $sql = new sql('localhost','livingsp_coach','R186er012qw5','livingsp_badminton');
|
|
|
|
if (empty($_GET['lease_id']) || 'null' == $_GET['lease_id']) {
|
|
echo json_encode(null);
|
|
}
|
|
else {
|
|
$l_query = "SELECT l_sum, l_expire_type, l_expire_date FROM lease WHERE l_id = " . $_GET['lease_id'];
|
|
|
|
$l_res = $sql->assoc_array($l_query);
|
|
|
|
echo json_encode($l_res[0]);
|
|
}
|
|
|
|
?>
|