这是我在HTML 5中的网站代码在这段代码中,我们制作了一些部分,因为你看到标题横幅和导航我不明白为什么我们在相同的代码中分别编写标题横幅和导航这是什么背后的主要原因制作这些部分?我不明白横幅代码为什么我们使用横幅代码?
<!-- Header -->
<header id="header">
<div class="logo container">
<div>
<h1><a href="index.html" id="logo">Malik Waqar Azim</a></h1>
<br><br>
<p>Bachelors in Software Engineering</p>
</div>
</div>
</header>
<!-- Nav -->
<nav id="nav">
<ul>
<li><a href="index.html">Home</a></li>
<li class="current"><a href="about-me.html">About Me</a></li>
<li><a href="contact-me.html">Contact Me</a></li>
</ul>
</nav>
<!-- Banner -->
<div id="banner-wrapper">
<section id="banner">
<h2>About Me</h2>
<p>I am currently pursuing bachelors in software engineering at UET Taxila.</p>
<p>I completed my intermediate and matriculation from Fauji Foundation College Lalazar</p>
</section>
</div>
答案 0 :(得分:0)
html5语言中的不同部分类似于某些内容的框。 HTML5语言制作您网页文档的结构。每个Web浏览器都有自己的标准CSS样式。如果您没有链接自定义样式,则使用此样式来了解如何显示html元素。 这个横幅是div-box,其中有关于你的信息。在这个例子中你有id的id。如果要为此特定框设置某些样式,则“id”属性是必需的。