-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.php
83 lines (74 loc) · 1.5 KB
/
index.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
<!DOCTYPE html>
<html>
<head>
<style type="text/css">
tr:hover {background-color: #ddd;}
th,tr,td{
border:2px solid black;
text-align:left;
text-style:Times New Roman;
border-color:black;
padding:1px 2px;
}
th{
background-color: #4CAF50;
}
header{
padding:30px;
background-color:#EEE;
}
table#t01 th {
background-color: black;
color: white;
}
table#t01 tr:nth-child(even) {
background-color: #eee;
}
</style>
<title>Home</title>
</head>
<?php
$servername = "localhost";
$username = "root";
$password = "";
$dbname = "project";
// Create connection
$conn = new mysqli($servername, $username, $password, $dbname);
// Check connection
if ($conn->connect_error) {
die("Connection failed: " . $conn->connect_error);
}
?>
<center>
<table>
<tr>
<th> Company Name </th>
<th> Email </th>
<th> Mobile </th>
<th> Hr Name </th>
<th> Address </th>
<th> File </th>
<th> password </th>
</tr>
<?php
$sql1 = "select * from register";
//$query = "select * from images";
$result=mysqli_query($conn,$sql1);
?>
<?php foreach ($result as $item): ?>
<tr>
<td><?php echo $item['Cname'] ; ?></td>
<td><?php echo $item['Email']; ?></td>
<td><?php echo $item['Mobile'] ; ?></td>
<td><?php echo $item['Hrname'] ; ?> </td>
<td><?php echo $item['address']; ?> </td>
<!--<td><?php echo $item['image']; ?> </td>-->
<td><a href="uploads/<?php echo $item['image'] ?>" target="_blank">view file</a></td>
</td>
<td><?php echo $item['password'] ;?></td>
</tr>
<?php endforeach; ?>
</table>
</center>
</body>
</html>