关于餐厅的代码HTML css
时间: 2023-12-24 17:23:14 浏览: 22
好的,以下是一个简单的餐厅网站的代码模板,包含HTML和CSS,可以根据实际需要进行修改和完善:
```html
<!DOCTYPE html>
<html>
<head>
<title>My Restaurant</title>
<link rel="stylesheet" type="text/css" href="style.css">
</head>
<body>
<header>
<nav>
<ul>
<li><a href="#">Home</a></li>
<li><a href="#">Menu</a></li>
<li><a href="#">Reservations</a></li>
<li><a href="#">About Us</a></li>
<li><a href="#">Contact</a></li>
</ul>
</nav>
</header>
<main>
<section class="hero">
<h1>Welcome to My Restaurant</h1>
<p>We offer a wide variety of delicious dishes, prepared with fresh, locally-sourced ingredients.</p>
<a href="#" class="btn">View Menu</a>
<a href="#" class="btn">Make a Reservation</a>
</section>
<section class="about">
<h2>About Us</h2>
<p>My Restaurant is a family-owned business that has been serving the community for over 20 years. Our menu features a variety of cuisines, including Italian, French, and Asian, as well as vegetarian and gluten-free options. We are committed to providing our customers with high-quality, delicious food and exceptional service.</p>
</section>
<section class="menu">
<h2>Our Menu</h2>
<div class="item">
<h3>Spaghetti Carbonara</h3>
<p>Spaghetti pasta with bacon, eggs, and Parmesan cheese.</p>
<span class="price">$12</span>
</div>
<div class="item">
<h3>Beef Bourguignon</h3>
<p>Tender beef stewed in red wine with mushrooms and onions.</p>
<span class="price">$18</span>
</div>
<div class="item">
<h3>Pad Thai</h3>
<p>Stir-fried rice noodles with shrimp, chicken, and vegetables in a tangy sauce.</p>
<span class="price">$14</span>
</div>
</section>
<section class="reservations">
<h2>Reservations</h2>
<p>To make a reservation, please call us at 555-1234 or use our online reservation system.</p>
<a href="#" class="btn">Make a Reservation</a>
</section>
</main>
<footer>
<p>© 2021 My Restaurant. All rights reserved.</p>
</footer>
</body>
</html>
```
在这个代码模板中,我们使用了HTML和CSS来构建一个简单的餐厅网站。网站包含一个导航栏、一个主体部分和一个页脚。主体部分包括一个主页区域、一个关于我们区域、一个菜单区域和一个预订区域。我们为网站设置了一些样式,使其更加美观和易于阅读。需要注意的是,这个代码模板只是一个示例,实际情况下需要根据具体需要进行修改和完善。