+ 1
Can someone please help me with my CSS code?
Can someone please help to check my code? the CSS does not show on my HTML side when I run it. I just need to know what is wrong, what I did that's wrong. Please help
14 Answers
+ 3
Hey Lizby Oosthuizen , it would be really helpful if you could share your code using the code playground. I've already done that for you, but it's better if you have it ready when you have questions about code. I have formated your CSS, that automatically solved the problem you were having with “center”. Formatting your code makes it easier to see where other issues are. Have a look.
https://sololearn.com/compiler-playground/W9jbCPeOJ93d/?ref=app
+ 1
Fabian Roy I guess you got a mistake
<link rel="stylesheet" href="styles.css">
+ 1
Do you know how to access the code playground?
0
double check the url of css file provided...
0
You didn't provide the code. Btw please check if the <link src="style.css"> line exists in the header section of the HTML file or not.
0
I will post my code here. Its on the learning platform
0
header {
text-align: center;
background-color: #eeeeee;
padding-top: 2px;
padding-bottom: 2px;
h1 {text-transform:uppercase; color:red;}
#position {font-size:18px; text-align:center; font-weight:800;}
.summary {font-size:16px; line-height:20px;center;}
h2 {font-size:20px; color:#2F5A78; padding-bottom: 2px; border-bottom: 1px solid ;}
copywrite {text-align:center;}
section, footer {padding: 2px 10px; background-color:#eeeeee;}
ul {margin: 1px solid #F5SA78;}
li b {
color: #2F5A78;
}
li {
margin-bottom: 5px;
}
footer a {color: #e99f4b; text-decoration: none}
footer a:hover { text-decoration:underline;}
table {
border-collapse: collapse;
}
td, th {
border:1px solid #000000;
padding: 5px;
}
th {
background-color: #2F5A78;
color: #FFFFFF;
}
0
Its picks up and changes the style up until summary. Then nothing happens after that
0
<!DOCTYPE html>
<html>
<body>
<header>
<h1>Lizby Oosthuizen</h1>
<p id="position">Software Engineer</p>
</header>
<section>
<h2>Summary</h2>
<p class="summary"><img src="https://cdn2.iconfinder.com/data/icons/avatars-99/62/avatar-370-456322-512.png" width="80px" alt="">
Deadline-oriented software engineer with lots of experience. Solid track record of architecting solutions that exceed client expectations.</p>
</section>
<section>
<h2>Experience</h2>
<ul id="experience">
<li>
<b>Senior Software Engineer - Google</b> | 2018 - Present
</li>
<li>
<b> Software Engineer - Facebook</b> | 2016 - 2018
</li>
</ul>
</section>
<section>
<h2>Skills</h2>
<table id="skills">
<tr><th>Skill</th><th>Level</th></tr>
<tr><td>HTML</td><td>Expert</td></tr>
<tr><td>CSS</td><td>In
0
How to save a html css js file
0
.summary {font-size:16px; line-height:20px;center;}
What's center? Did you miss text-align? Maybe it's "text-align: center"
And also I think you miss the closing curly brace for header styling.
0
Probably I'll fix that. Thank you so much
0
You're correct! "center" in CSS typically refers to the alignment of content horizontally within an element. To align text in the center horizontally, the correct CSS property is indeed "text-align: center".
0
Thank you so much. I didn't know I can share it with the playground...