custom training price
This commit is contained in:
19
_ajax/get_trt_default_price.php
Normal file
19
_ajax/get_trt_default_price.php
Normal 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','id9073794_tollashodos','uprRscU8bGpJ','id9073794_tollashodos');
|
||||
|
||||
if (empty($_GET['trt_id'])) {
|
||||
echo json_encode(null);
|
||||
}
|
||||
else {
|
||||
$trt_query = "SELECT trt_default_price FROM training_type WHERE trt_id = " . $_GET['trt_id'];
|
||||
|
||||
$trt_default_price = $sql->single_variable($trt_query);
|
||||
|
||||
echo json_encode($trt_default_price);
|
||||
}
|
||||
|
||||
?>
|
||||
Reference in New Issue
Block a user