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 trial
Eric Read
2,222 Points"​" added to my code and is messing with my <head> (lol jokes)
Hey!
So i'm trying to design my website using Sublime Text 2 and it's adding:
​
to my <body> tag, thus taking information that is supposed to belong in my <head> tab and putting it in my <body> tag, though you can't see it in the body of my website. Everything is still locally hosted so I don't have it uploaded yet, but here is what the <head> code is supposed to look like:
<head>
<meta charset="UTF-8">?
<title>Eric Read</title>
<link rel="stylesheet" type="text/css" href="normalize.css">
<link rel="stylesheet" type="text/css" href="main.css">
<meta name="viewport" content="width=device-width">
</head>
and here is what it shows up when I expect the element in Google Chrome:
<head>
<meta charset="UTF-8">?
</head>
<body>
"​
"
<title>Eric Read</title>
<link rel="stylesheet" type="text/css" href="normalize.css">
<link rel="stylesheet" type="text/css" href="main.css">
<meta name="viewport" content="width=device-width">
I think it's messing up my code a little bit, so any help would be great!
Thanks!
-e
1 Answer
Dewey Vozel
18,250 PointsYour title, links and meta tags should be in your head tag, not the body... as Hayden posted. The mystery character is probably from a character that got grabbed from a copy/paste on a web page or something (or maybe you accidentally pressed a key combination that inserted it). You can try in Sublime Text to do File > Save with Encoding > UTF-8 to see if that gets rid of it. If that doesn't work, you could try to follow the information below to adjust your user settings temporarily to cause it to display the "hidden" characters.
Hayden Taylor
5,076 PointsIt also may be a language setting.
Hayden Taylor
5,076 PointsHayden Taylor
5,076 PointsThis prob won't fix it but..... you got a ? after "<meta charset="UTF-8">" and... typically
you want your title tag under your style sheet links and meta tags so
try that