mirror of
https://github.com/FH-Complete/FHC-Core.git
synced 2026-06-01 12:19:28 +00:00
8298342967
lehrveranstaltung.php: Button zum Anlegen von Lehrfächern lehrfach.php: Neuer Tablesorter reservierung_insert.php: Ort mit Autocomplete und Datum mit Datepicker
50 lines
1.6 KiB
PHP
50 lines
1.6 KiB
PHP
<?php
|
|
/* Copyright (C) 2010 Technikum-Wien
|
|
*
|
|
* This program is free software; you can redistribute it and/or modify
|
|
* it under the terms of the GNU General Public License as
|
|
* published by the Free Software Foundation; either version 2 of the
|
|
* License, or (at your option) any later version.
|
|
*
|
|
* This program is distributed in the hope that it will be useful,
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
* GNU General Public License for more details.
|
|
*
|
|
* You should have received a copy of the GNU General Public License
|
|
* along with this program; if not, write to the Free Software
|
|
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
|
|
*
|
|
* Authors: Manfred Kindl <kindlm@technikum-wien.at>
|
|
*/
|
|
|
|
require_once('../../config/vilesci.config.inc.php');
|
|
require_once('../../include/basis_db.class.php');
|
|
require_once('../../include/ort.class.php');
|
|
|
|
if (!$db = new basis_db())
|
|
die('Es konnte keine Verbindung zum Server aufgebaut werden.');
|
|
|
|
if(isset($_REQUEST['autocomplete']) && $_REQUEST['autocomplete']=='ort')
|
|
{
|
|
$search=trim((isset($_REQUEST['term']) ? $_REQUEST['term']:''));
|
|
if (is_null($search) ||$search=='')
|
|
exit();
|
|
|
|
$ort_auswahl = new ort();
|
|
|
|
if($ort_auswahl->filter($search))
|
|
{
|
|
$result_obj = array();
|
|
foreach($ort_auswahl->result as $row)
|
|
{
|
|
$item['ort_kurzbz']=html_entity_decode($row->ort_kurzbz);
|
|
$item['planbezeichnung']=html_entity_decode($row->planbezeichnung);
|
|
$result_obj[]=$item;
|
|
}
|
|
echo json_encode($result_obj);
|
|
}
|
|
exit;
|
|
}
|
|
?>
|