Hello freecodecamp,
This is my first attempt at coding. I’m just making a webpage using texteditor. But for some reason my css element isn’t updating in the browser. When I view the source code through my browser, the link to my css is there, as well as the rest of my html file. So I’m thinking my problem may lie in the css file?
I have both files saved into one folder, index is the title of my html document, and style.css is the name of my css.
I have enabled plain text, not rtf format.
this is my html:
<html>
<head>
<title>my website</title>
<link rel=“stylesheet” type=“text/css” href=“style.css”/>
</head>
<body>
<div id=“container”>
<div id=“header”>
<h1>my website</h1>
</div>
<div id=“content”>
<div id=“nav”>
<h3>navigation</h3>
<ul>
<li>home</li>
<li>about</li>
<li>contact</li>
</ul>
</div>
<div id=“main”>
<h2>home page</h2>
<h2>home page</h2>
<p> asjkahsdaskaskhda</p>
<p> sjakjshdakjsdhahka</p>
<p> asjdhaskhdashdkas</p>
</div>
<div id=“footer”>
copyright © 2016
</div>
</html>
this is my css:
body {
background-color: #EEE;
}
#container {
background-color: white;
width: 800px;
margin-left: auto;
margin-right: auto;
}
#header {
background-color: #66CCFF;
color: white;
text-align: center;
}
hoping someone could chime in