-
Notifications
You must be signed in to change notification settings - Fork 2
/
searcher.php
268 lines (252 loc) · 8.22 KB
/
searcher.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
<?php
// Funciones de conexión con la base de dato
require 'funciones.php';
//error_reporting(E_ALL);
$link = conectar();
session_start();
seguridad();
/*
echo "<pre>";
echo var_dump($_SESSION);
echo "</pre>";
*/
/*
echo "<pre>";
echo var_dump($_POST);
echo "</pre>";
*/
?>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Chamilo - Search</title>
<meta content="Chamilo - Members Management" name="description">
<!-- We need to emulate IE7 only when we are to use excanvas -->
<!--[if IE]> <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" /> <![endif]-->
<!-- Favicons -->
<!-- Main Stylesheet -->
<link type="text/css" href="css/style4.css" rel="stylesheet">
<!-- <link type="text/css" href="css/green.css" rel="stylesheet">-->
<!-- Your Custom Stylesheet -->
<link rel="stylesheet" type="text/css" href="css/jquery-ui-1.8.17.custom.css" media="screen">
<link rel="stylesheet" type="text/css" href="css/custom.css" media="screen">
<!-- jQuery with plugins -->
<script src="js/jquery-1.8.2.js" type="text/javascript"></script>
<!-- Could be loaded remotely from Google CDN : <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> -->
<script src="js/jquery.ui.core.min.js" type="text/javascript"></script>
<script src="js/jquery.ui.widget.min.js" type="text/javascript"></script>
<script src="js/jquery.ui.tabs.min.js" type="text/javascript"></script>
<!-- jQuery tooltips -->
<script src="js/jquery.tipTip.min.js" type="text/javascript"></script>
<!-- Superfish navigation -->
<script src="js/jquery.superfish.min.js" type="text/javascript"></script>
<script src="js/jquery.supersubs.min.js" type="text/javascript"></script>
<!-- jQuery popup box -->
<script src="js/jquery.nyroModal.pack.js" type="text/javascript"></script>
<!-- jQuery graph plugins -->
<!--[if IE]><script type="text/javascript" src="js/flot/excanvas.min.js"></script><![endif]-->
<script src="js/flot/jquery.flot.min.js" type="text/javascript"></script>
<!-- Internet Explorer Fixes -->
<!--[if IE]> <link rel="stylesheet" type="text/css" media="all" href="css/ie.css"/> <script src="js/html5.js"></script> <![endif]-->
<!--Upgrade MSIE5.5-7 to be compatible with MSIE8: http://ie7-js.googlecode.com/svn/version/2.1(beta3)/IE8.js -->
<!--[if lt IE 8]> <script src="js/IE8.js"></script> <![endif]-->
<script type="text/javascript">
$(document).ready(function(){
/* setup navigation, content boxes, etc... */
Administry.setup();
});
</script>
<script src="js/jquery-ui.min.js" type="text/javascript"></script>
<script type="text/javascript">
$(document).ready(function() {
$("#renewal_ini, #renewal_fin, #arrival_ini, #arrival_fin").datepicker({
dateFormat: 'dd/mm/yy',
changeMonth: true,
changeYear: true
});
});
</script>
<script src="js/conf_searcher.js" type="text/javascript"></script>
</head>
<body>
<!-- Header -->
<header id="top">
<div class="wrapper">
<!-- Title/Logo - can use text instead of image -->
<div id="title">
<img alt="Members Management" src="images/logo.png">
<!--<span>Administry</span> demo-->
</div>
<!-- Top navigation -->
<div id="topnav">
Logged in as
<b><?php echo $_SESSION['usuario']; ?></b>
<span>|</span>
<a href="setting.php">Settings</a>
<span>|</span>
<a href="logout.php">Logout</a>
<br>
</div>
<!-- End of Top navigation -->
<!-- Main navigation -->
<?php include_once 'menu/top-menu.php'; ?>
<!-- End of Main navigation -->
</div>
</header>
<!-- End of Header -->
<!-- Page title -->
<div id="pagetitle">
<div class="wrapper">
<h1>Search</h1>
</div>
</div>
<!-- End of Page title -->
<!-- Page content -->
<div id="page">
<?php
if(isset($_SESSION['info']) && $_SESSION['info']!=''){
echo '<div class="box box-success closeable">'.$_SESSION['info'].'</div>';
unset($_SESSION['info']);
}
?>
<!-- Wrapper -->
<div class="wrapper">
<!-- Left column/section -->
<section class="column width8 first">
<form action="#" id="form_searcher" method="post" >
<div align="center">
<table border="0" width="100%" id="tbl_estilo1">
<tr><th>Search form</th></tr>
<tr>
<td>
Name: <input type="text" name="name" id="name" size="23" />
<!--Surname: <input type="text" name="surname" id="surname" size="23" />-->
Institution: <input type="text" name="institution" id="institution" size="23" />
Email: <input type="text" name="email" id="email" size="23" />
<br /><br />
Country
<select name="country" id="country" style="width:200px">
<?php
$link = conectar();
$sql = "SELECT * FROM country";
echo '<option value=""></option>';
$result = $link->query($sql);
if(!$result){
die('Invalid query: ' . $link->error);
}
while($row = $result->fetch_assoc()){
echo '<option value="'.$row['iso'].'" style="max-width:200px">'.$row['name'].'</option>';
}
$result->free_result();
$result->close();
?>
</select>
Phone: <input type="text" name="phone" id="phone" size="17" />
Quota: <input type="text" name="quota" id="quota" size="10" />
<br /><br />
Member type:
<select name="type" id="type">
<?php
$link = conectar();
$sql = "SELECT * FROM type_member";
echo '<option value=""></option>';
$result = $link->query($sql);
if(!$result){
die('Invalid query: ' . $link->error);
}
while($row = $result->fetch_assoc()){
echo '<option value="'.$row['cod'].'" style="max-width:200px">'.$row['name'].'</option>';
}
$result->free_result();
$result->close();
?>
</select>
Status:
<select name="status" id="status">
<?php
$link = conectar();
$sql = "SELECT * FROM status";
$result = $link->query($sql);
if (!$result) {
die('Invalid query2: ' . $link->error);
}
echo '<option value="" selected="selected"></option>';
while($row = $result->fetch_assoc()){
echo '<option value="'.$row['cod'].'">'.$row['status'].'</option>';
}
$result->free_result();
$result->close();
?>
</select>
Language:
<select name="language" id="language">
<?php
echo '<option value="" selected="selected"></option>';
$link = conectar();
$sql = "SELECT * FROM language WHERE active='1' ORDER BY language ASC";
$result = $link->query($sql);
if (!$result) {
die('Invalid query2: ' . $link->error);
}
while($row = $result->fetch_assoc()){
echo '<option value="'.$row['cod'].'">'.$row['language'].'</option>';
}
$result->free_result();
$result->close();
?>
</select>
<br /><br />
Renewal date between:
<input type="text" name="renewal_ini" id="renewal_ini" placeholder="dd/mm/yyyy" />
to
<input type="text" name="renewal_fin" id="renewal_fin" placeholder="dd/mm/yyyy" />
<?php
if(Comprobariexplorer($_SERVER['HTTP_USER_AGENT'])){
echo ' (dd/mm/yyyy)';
}
?>
<br /><br />
Registration date between:
<input type="text" name="arrival_ini" id="arrival_ini" placeholder="dd/mm/yyyy" />
to
<input type="text" name="arrival_fin" id="arrival_fin" placeholder="dd/mm/yyyy" />
<?php
if(Comprobariexplorer($_SERVER['HTTP_USER_AGENT'])){
echo ' (dd/mm/yyyy)';
}
?>
</td>
</tr>
<tr><td class="center">
<div class="center">
<input type="button" class="btn btn-green big" id="buscar" name="enviar" value="Search" />
<input type="button" class="btn btn-red big" id="reset" name="reset" value="Reset" />
</div>
</td></tr>
</table>
</div>
</form>
<div id="result_searcher"></div>
<div id="result_edit"></div>
</section>
<!-- End of Left column/section -->
</div>
<!-- End of Wrapper -->
</div>
<!-- End of Page content -->
<!-- Page footer -->
<?php include_once 'menu/footer-menu.php'; ?>
<!-- End of Animated footer -->
<!-- Scroll to top link -->
<a id="totop" style="display: block;">^ scroll to top</a>
<!-- Admin template javascript load -->
<script src="js/administry.js" type="text/javascript"></script>
<div id="tiptip_holder" style="max-width:200px;">
<div id="tiptip_arrow">
<div id="tiptip_arrow_inner"></div>
</div>
<div id="tiptip_content"></div>
</div>
</body>
</html>