好吧,我对编程来说是 100% 的新手。问题格式也可能是错误的。 问题:html 上的主题? 还是 html 初学者。希望它看起来美观,至少根据我所学到的知识。还没有 CSS 知识。我一直在搜索我想放在页面上的任何内容(表情符号)。 我已经搜索了谷歌并做了所写的内容,但它仍然没有显示主题。 好的,这是代码,以便您可以看到,稍后我会根据学习添加更多内容(我知道这对你们来说没什么用):
<html>
<head>
<meta charset=“UTF-8”>
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="theme-color" content="#f7cac9">
<title>Galaxia
</title>
</head>
<body>
<h3 style = "position:absolute; right:150px; top:-10px; background-color:pink;">
Welcome to my weird abode 🦋
</h3>
<br>
<br>
<!-- added two br tags because otherwise heading and paragraph overlap -->
<div class="coder">
<p>This is a html example from me for now,
<br>
have fun.:) </p>
</div>
</body>
</html>
提前谢谢您!
为了向 HTML 页面添加样式,您可以使用 css(文件扩展名为 .css - 例如
styles.css
)。要使样式在 html 页面上可见,请在 head 部分中包含 <link rel="stylesheet" href="styles.css"/>
。例如,在 css 文件中,您可以包含:
h3 {
color: #f7cac9;
}
然后,添加链接rel后,html页面中的h3元素将变成粉红色。希望这可以帮助!或者,您可以在 html 页面中添加标签。
以下是向 html 页面添加 css 的示例。通过添加 .coder {background: green},背景颜色变为绿色:
.coder {
background-color: green;
}
<html>
<head>
<meta charset=“UTF-8”>
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="theme-color" content="#f7cac9">
<title>Galaxia
</title>
</head>
<body>
<h3 style = "position:absolute; right:150px; top:-10px; background-color:pink;">
Welcome to my weird abode 🦋
</h3>
<br>
<br>
<!-- added two br tags because otherwise heading and paragraph overlap -->
<div class="coder">
<p>This is a html example from me for now,
<br>
have fun.:) </p>
</div>
</body>
</html>
就像其他人的帖子一样。
<p>This is a paragraph</p>
可以找到快速教程的地方是 w3schools.com。
很有名,很多人都用它。
希望你继续努力。
第一步是最难的!