Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialoren tal
5,738 Pointsneed some help
well, in the preview i dont see the pictures and the css file doesnt effect it to and doesnt change the background color
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>OREN|YORGEN</title>
<link rel="stylesheet" href="css/normalize.css">
<link rel="stylesheet" href="css/main.css">
</head>
<body>
<header>
<a href="index.html">
<h1>OREN|YORGEN</h1>
<h2>snails expert</h2>
</a>
<nav>
<ul>
<li><a href="index.html">portfolio</a></li>
<li><a href="about.html">about</a></li>
<li><a href="contact.html">contact</a></li> </ul>
</nav>
</header>
<section>
<ul>
<li>
<img src="img/mara.jpg alt="">
<p>pppppppp</p>
</li>
<li>
<img src="img/snork.jpg alt="">
<p>rrrrr</p>
</li>
<li>
<img src="img/tzav.jpg alt="">
<p>dfdffddf</p>
</li>
</ul>
</section>
<footer>
<p>© 2015 yorgen.</p>
<img src="img/twitter.png" alt="twitter logo">
<img src="img/facebook.png" alt="facebook logo">
</footer>
</body>
</html>
body {
background-color: orange;
}
9 Answers
sizwengubane
15,244 PointsHello. You have made some small mistakes on your code, in your image tags you have not used the closing quote marks in the required place...the fixed code looks like this <blockquotes>
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>OREN|YORGEN</title>
<link rel="stylesheet" href="css/normalize.css">
<link rel="stylesheet" href="css/main.css">
</head>
<body>
<header>
<a href="index.html">
<h1>OREN|YORGEN</h1>
<h2>snails expert</h2>
</a>
<nav>
<ul>
<li><a href="index.html">portfolio</a></li>
<li><a href="about.html">about</a></li>
<li><a href="contact.html">contact</a></li> </ul>
</nav>
</header>
<section>
<ul>
<li>
<img src="img/mara.jpg" alt="">
<p>pppppppp</p>
</li>
<li>
<img src="img/snork.jpg" alt="">
<p>rrrrr</p>
</li>
<li>
<img src="img/tzav.jpg" alt="">
<p>dfdffddf</p>
</li>
</ul>
</section>
<footer>
<p>© 2015 yorgen.</p>
<img src="img/twitter.png" alt="twitter logo">
<img src="img/facebook.png" alt="facebook logo">
</footer>
</body>
</html>
</blockquotes> Hope this helps...and there is nothing wrong with the way u included the css file to your html document using the 'link' element...so check the file's name and try again. Rate my answer as the best if i managed to help u
oren tal
5,738 Pointsthanks i'have changed the img ilne and it works now. still the css file doesnt affect the page. here it is
a {
background-color: blue;
}
sizwengubane
15,244 Pointswhat is the file name you are using for ur css file? and what folder is it in?
oren tal
5,738 Pointsmain.css in css folder
sizwengubane
15,244 Pointswhere is the html file in? inside a seperate folder or common folder?
oren tal
5,738 Pointsit is out side the css and the img folders
sizwengubane
15,244 Pointswtf? then why is it now working? try creating another stylesheet or just check weather u have properly saved your changes in the css file
oren tal
5,738 Pointsi think it works fine now :) can i bother you with another question?
sizwengubane
15,244 Pointssure but please mark my first answer as the best..so i can get points ^_^
oren tal
5,738 Pointsto mark it means turn it from 0 to 1? i just did.
so i want to open the index document from the download files so i can get help from it. after i open it in workspace i change my files name to index1.html and main1.html so i can view them both but it previewed only the index.html
sizwengubane
15,244 Pointsno bro...there will be an option like 'select as best answer' anyway...the name 'index.html' is given to an html document because its the main document. workspaces will automatically open up the 'index.html' file when u click on preview..if u want to open any other file u must right click on the file and say open
oren tal
5,738 Pointsso you think it's better to get help from the videos and not opening the ready index.html?
Daniel Čupak
6,602 Pointsso your file structure looks as follows?
project(folder) ->img (folder) -->mara.jpg ->css (folder) --> main.css ->main.html
it does not affect the main.html at all?