Membuat Professional Website (UMKM Makanan) Dengan HTML Dan CSS Dalam 1 Jam
Table of Contents
Introduction
In this tutorial, you'll learn how to create a professional website for your food-based small business (UMKM) using HTML and CSS in just one hour. This guide is perfect for those who have a business but lack an online presence. Following these steps will help you set up a simple yet effective website to showcase your products.
Step 1: Setting Up Your HTML Structure
-
Create a New HTML File
- Open your text editor (like Visual Studio Code or Notepad++).
- Create a new file and save it as
index.html
.
-
Basic HTML Template
- Start with the following basic template:
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Your Business Name</title> <link rel="stylesheet" href="styles.css"> </head> <body> <header> <h1>Welcome to Your Business</h1> </header> <main> <section id="products"> <h2>Our Products</h2> </section> </main> <footer> <p>Contact us at: [Your Contact Information]</p> </footer> </body> </html>
-
Add Content
- In the
<section id="products">
, list your products using<ul>
and<li>
tags.
- In the
Step 2: Styling with CSS
-
Create a New CSS File
- In the same directory, create a new file named
styles.css
.
- In the same directory, create a new file named
-
Basic CSS Setup
- Add the following CSS to style your website:
body { font-family: Arial, sans-serif; margin: 0; padding: 0; background-color: #f4f4f4; } header { background: #35424a; color: white; padding: 20px 0; text-align: center; } main { padding: 20px; } footer { text-align: center; padding: 10px 0; background: #35424a; color: white; }
-
Customize Your Styles
- Modify colors, fonts, and layouts to match your brand identity.
Step 3: Adding Images
-
Image Placement
- To include images of your products, add
<img>
tags in the products section:
<img src="path/to/image.jpg" alt="Product Name">
- To include images of your products, add
-
Ensure Accessibility
- Always use alt attributes to describe your images for better accessibility.
Step 4: Responsive Design
- Media Queries
- To ensure your website looks good on all devices, add the following to your CSS:
@media (max-width: 600px) { header, footer { padding: 10px; } main { padding: 10px; } }
Step 5: Testing Your Website
-
Open Your HTML File
- Open
index.html
in a web browser to see how your website looks.
- Open
-
Check Functionality
- Ensure all links and images are working as intended.
Conclusion
Congratulations! You have successfully created a professional website for your food-based business using HTML and CSS. Remember to keep your content updated and consider adding more features like a contact form or social media links as you grow. If you're interested in enhancing your web design skills further, consider joining an intensive web design course.