-
Notifications
You must be signed in to change notification settings - Fork 0
/
page4.php
57 lines (49 loc) · 1.24 KB
/
page4.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
<!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1.0" charset = "UTF-8">
<link rel="stylesheet" type = "text/css" href= "style.css" />
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
</head>
<?PHP
include("db_connection.php");
$query = "SELECT
change_management.ID,
change_management.creationdate,
change_management.title,
change_management.Notes,
kategorije.name
FROM change_management LEFT JOIN kategorije ON (change_management.CategoryID = kategorije.ID)
WHERE change_management.CategoryID = '4'";
$result = mysql_query($query);
$i = 1;
if($result){
while($row = mysql_fetch_array($result)){
$id = $row["ID"];
$create_date = $row["creationdate"];
$title = $row["title"];
$notes = $row["Notes"];
$cat_name = $row["name"];
echo '
<table border="1" style="table-layout:fixed;width:85%;text-align:center;">
<thead>
<tbody>
<tr style="width:17%">
<td>'.$i.'.</td>
<td>'.$create_date.'</td>
<td>'.$title.'</td>
<td>'.$notes.'</td>
<td>'.$cat_name.'</td>
</tr>
</tbody>
</thead>
</table>';
$i++;
}
}
else{
echo "Nema rezultata za prikaz";
echo mysql_error();
}
?>
</html>