首页 > 解决方案 > CSS3 没有链接到 HTML5?

问题描述

谁能告诉我为什么我的样式表不会链接到我的 html 文本?我觉得我已经在阳光下尝试了一切,现在只是茫然地盯着它。这可能是非常明显的事情。

h2 {
  font-family: sans-serif;
  text-align: center;
  color: blue;
}

p {
  font-family: sans-serif;
}
<!DOCTYPE html>
<html>

<head>
  <meta charset="utf-8">
  <title> Konrad Zuse </title>
  <link rel="stylesheet" type="text/css" href="stylesheet.css" media="screen" />
</head>

<h2> Konrad Zuse </h2>
<p> Konrad Zuse was a German computer scientist who is responsible for creating the worlds first programmable computer. </p>
<p> He also designed the first high-level programming language, Plankakül. </p>
<p> Born on the 22<sup>nd</sup> of June 1910 in Berlin his family moved to Braunsberg, now know as Braniewo, Poland. His father worked as a postal clerk whilst Zuse attended Collegium Hosianum. Zuse passed his Abitur in 1928, meaning he could go on to study at university. Attending the Technische Hochschule Berlin, now Technical University of Berlin, Zuse studied engineering and architecture both of which he found tedious. He began a path down civil engineering and graduated in 1935. Once graduated Zuse began work at the Henschel aircraft factory in Berlin. He was made to calculate routine maths by hand and started to think up a machine that would do his calculations for him. </p>

标签: htmlcss

解决方案


这里有一些提示。

当您加载页面时,右键单击页面并转到Inspect element. 然后转到Network选项卡,单击CSS复选框并刷新页面。它将显示它尝试加载的 css。如果文件名是白色的,则加载 CSS。如果不是,则可能是路径问题。Network如果您可以从控制台发布选项卡的图像会很酷

还。您缺少<body></body>和结束</html>标记。先处理好这个


推荐阅读