gpt-3.5-turbo-0613· OpenAI
WildChat-4.8M (AI2)
salut, peux tu m'ecrire un code Html pour la page d'accueil d'un site marchand
- User
salut, peux tu m'ecrire un code Html pour la page d'accueil d'un site marchand
- Assistant
Bien sûr ! Voici un exemple de code HTML pour une page d'accueil basique d'un site marchand :
<!DOCTYPE html> <html lang="fr"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Mon site marchand</title> <style> /* Styles CSS pour la mise en page */ body { font-family: Arial, sans-serif; margin: 0; padding: 0; } header { background-color: #333; color: #fff; padding: 20px; text-align: center; } h1 { margin: 0; } .container { max-width: 1200px; margin: 20px auto; padding: 0 20px; } .banner { width: 100%; max-height: 300px; } .product { display: flex; justify-content: center; margin-top: 40px; } .product img { max-width: 200px; margin-right: 20px; } .product h2 { margin: 0; } </style> </head> <body> <header> <h1>Mon site marchand</h1> </header> <div class="container"> <img class="banner" src="image-banner.jpg" alt="Bannière du site"> <section class="product"> <img src="image-produit.jpg" alt="Produit 1"> <div> <h2>Nom du produit 1</h2> <p>Description du produit 1</p> <p>Prix: 19,99€</p> </div> </section> <section class="product"> <img src="image-produit.jpg" alt="Produit 2"> <div> <h2>Nom du produit 2</h2> <p>Description du produit 2</p> <p>Prix: 29,99€</p> </div> </section> </div> </body> </html>Dans cet exemple, nous avons une structure de base avec un en-tête
<header>contenant un titre<h1>. Ensuite, nous avons une partie principale<div class="container">qui contient une bannière<img class="banner">et deux sections<section class="product">représentant des produits.Bien entendu, vous devrez personnaliser ce code en ajoutant vos propres images, descriptions de produits, etc.