-
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathh.html
More file actions
85 lines (78 loc) · 2.73 KB
/
h.html
File metadata and controls
85 lines (78 loc) · 2.73 KB
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
<?php
include 'db.php'
?>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Home</title>
<link rel="stylesheet" type="text/css" href="css/style.css">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.3/css/all.min.css" />
</head>
<body>
<!--===== HEADER =====-->
<header>
<div class="container">
<h1><a href="index.php">Himang</a></h1>
<ul>
<li><a href="produk.php">Produk</a></li>
</ul>
</div>
</header>
<!--===== SEARCH =====-->
<div class="search">
<div class="container">
<form action="produk.php">
<input type="text" name="search" placeholder="Cari Produk">
<input type="submit" name="Cari" value="Cari">
</from>
</div>
</div>
<!--===== KATEGORI =====-->
<div class="section">
<div class="container">
<h3>Kategori</h3>
<div class="box">
<?php
$kategori = mysqli_query($conn, "SELECT * FROM tb_kategori ORDER BY kategori_id DESC");
if(mysqli_num_rows($kategori) > 0 ){
while($k = mysqli_fetch_array($kategori)){
?>
<a href="produk.php?ka=<?php echo $k['kategori_id'] ?>">
<div class="col-5">
<img src="gbr/kategori.png" width="50px" style="margin-bottom: 5px" ;>
<p>
<?php echo $k['kategori_nama'] ?>
</p>
</div>
</a>
<?php }} else{ ?>
<p>Kategori Tidak Ada</p>
<?php } ?>
</div>
</div>
</div>
<!--===== KATEGORI =====-->
<div class="section">
<div class="container">
<h3>Produk Terbaru</h3>
<div class="box">
<?php
$produk = mysqli_query($conn, "SELECT * FROM tb_produk ORDER BY produk_id DESC LIMIT 6");
if(mysqli_num_rows($produk) > 0){
?>
<div class="col-3">
<img src="">
<p class="Nama">Nama Produk</p>
<p class="harga">Rp. 500.000</p>
</div>
<?php }else{ ?>
<p>Produk Tidak Ada</p>
<?php } ?>
</div>
</div>
</div>
</body>
</html>