Cengizhanjj
Femtopat
- Katılım
- 8 Aralık 2022
- Mesajlar
- 52
Daha fazla
- Cinsiyet
- Erkek
Selam arkadaşlar benim bir Websitem bar biz burda satış yapacağız ama nasıl parayı alabilirim Papara kullanıyorum.
Kodlar
Kodlar
HTML:
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8" />
<link rel="stylesheet" href="m.css">
<title>Market</title>
</head>
<body>
<header class="navbar-techno">
<ul>
<li>Ana Sayfa</li>
<li>About</li>
<li>Products</li>
</ul>
</header>
<main class="container">
<div class="product-section">
<h1>Ürünler</h1>
<ul class="product-list">
<li>
<div class="product-item">
<img src="https://via.placeholder.com/150" alt="Product Image" />
<h2>Ürün 1</h2>
<p>Açıklama: Ürün 1'in açıklaması</p>
<p>Fiyat: 100 TL</p>
<div class="button">
<button>Satın Al</button>
</div>
</div>
</li>
<li>
<div class="product-item">
<img src="https://via.placeholder.com/150" alt="Product Image" />
<h2>Ürün 2</h2>
<p>Açıklama: Ürün 2'nin açıklaması</p>
<p>Fiyat: xxx</p>
<div class="button">
<button>Satın Al</button>
</div>
</div>
</li>
</ul>
</div>
</main>
<footer>
</footer>
<script src="https://code.jquery.com/jquery-3.6.0.min.js"></script>
<script>
$(document).ready(function () {
$(".navbar").hide();
$("#showNavbar").click(function () {
$(".navbar").toggle();
});
});
</script>
</body>
</html>
CSS:
body {
background-image: url("https://cdn.pixabay.com/photo/2017/08/30/11/50/stripe-2696784_640.png");
margin: 0;
font-family: Arial, sans-serif;
}
.navbar-techno{
background-color: #fff;
height: 60px;
display: flex;
align-items: center;
}
.navbar-techno ul li{
padding: 10px;
border-radius: 4px;
}
.navbar-techno ul li:hover{
background-color: #red;
transition: 100ms;
cursor: pointer;
}
.container {
height: 100vh;
display: flex;
flex-wrap: wrap;
justify-content: center;
align-items: center;
}
ul {
display: flex;
list-style-type: none;
margin: 0;
padding: 0;
}
li {
margin: 0 10px;
}
li a {
color: #fff;
text-align: center;
padding: 14px 16px;
text-decoration: none;
}
li a:hover {
background-color: #fff;
color: #333;
}
button {
padding: 10px 20px;
border-radius: 5px;
background-color: red;
color: #fff;
border: none;
font-size: 14px;
cursor: pointer;
}
.product-section {
background-color: #fff;
padding: 20px;
box-shadow: 1px 1px 3px rgba(0, 0, 0, 0.1);
text-align: center;
}
.product-list {
display: flex;
flex-wrap: wrap;
justify-content: center;
align-items: center;
}
.product-item {
width: 60%;
background-color: #fff;
margin: 10px;
padding: 20px;
text-align: center;
box-shadow: 1px 1px 3px rgba(0, 0, 0, 0.1);
}
.product-item img {
width: 100%;
margin-bottom: 20px;
}
.product-item h2 {
font-size: 18px;
margin-bottom: 10px;
}
.product-item p {
font-size: 14px;
color: #333;
margin-bottom: 10px;
}
footer {
background-color: #333;
color: #fff;
text-align: center;
padding: 20px;
}
@media only screen and (max-width: 600px) {
.navbar {
flex-wrap: wrap;
justify-content: center;
}
.navbar button {
display: block;
margin: 10px 0;
}
ul {
flex-wrap: wrap;
justify-content: center;
}
.product-section {
padding: 10px;
}
.product-item {
width: 100%;
margin: 5px;
padding: 10px;
}
}