lease can be chosen from money deposit form

This commit is contained in:
Tóth Richárd
2019-08-26 16:16:55 +02:00
parent 5bef1596f4
commit 502531afaf
9 changed files with 215 additions and 83 deletions

19
_ajax/get_lease_sum.php Normal file
View File

@@ -0,0 +1,19 @@
<?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('bcd_mysql','root','','badminton_coach');
else $sql = new sql('localhost','livingsp_coach','R186er012qw5','livingsp_badminton');
if (empty($_GET['lease_id'])) {
echo json_encode(null);
}
else {
$l_query = "SELECT l_sum FROM lease WHERE l_id = " . $_GET['lease_id'];
$l_sum = $sql->single_variable($l_query);
echo json_encode($l_sum);
}
?>