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

HTML

Sean Lopez
Sean Lopez
6,783 Points

Front End Project 1- Not working in IE

<!doctype html>
<html lang='eng'>
 <head>
  <meta charset="utf-8">
  <title>Sean Lopez's Profile</title>
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <link rel="stylesheet" href="styles.css">
<link href="https://fonts.googleapis.com/css?family=Julius+Sans+One" rel="stylesheet">
  <body>

    <div class="main-nav">
        <ul class="nav">
          <li class="name">Sean Lopez</li>
          <li><a href="index.html">Home</a></li>
          <li><a href="experience.html">Experience</a></li>
          <li><a href="about.html">About</a></li>
        </ul>
    </div>

    <header>
      <img src="images/meimage.jpg" alt="Drawing of Sean Lopez" class="profile-image">
      <h1 class="tag name">lopez</h1>
      <p>in</p>
      <h3 class="tag location">saigon</h3>
    </header>

    <main class="flex">
      <div class="card">
        <h2>Location</h2>
          <img src="images/saigonsunset.jpg" alt="sunrise" class= "image1">
        <p> I'm an educator at a university in Ho Chi Minh City, Vietnam. I have been teaching here for 10 years with a focus on technology enhanced learning.</p>

      </div>   

      <div class="card">
        <h2>Fortune</h2>
        <img src="images/threekings.jpg" alt="Three kings" class= "image3">
        <ul class="skills">
          <li>HTML</li>
          <li>CSS</li>
          <li>JavaScript</li>
         <h3>The 'Lucky Three'</h3>
         </ul>
      </div>

    </main>
    <footer>
      <ul>
        <li><a href="http://twitter.com/lopezvietnam" class="social twitter">Twitter</a></li>
        <li><a href="http://github.com/Lopezvietnam" class="social github">Github</a></li>
      </ul>
      <p class="copyright">Copyright 2017, Sean Lopez</p>
    </footer>
  </body>
</html>

CSS

/* Global Layout Set-up */
* { 
  box-sizing: border-box;

}

body {
  margin: 0;
  padding: 0;
  text-align: center;
  font-family: 'Julius Sans One', sans-serif, 'Arial';
  background: linear-gradient (lightSalmon, #999);
}
/* Link Styles */

a {
  text-decoration: none;
  color: #999;
}

a:link {
  color: salmon;
  text-decoration: none;
}

a:visited {
  color: lightblue;
}
a:hover {
  color: #6633ff;
}
a:active {
  color: lightcoral;
}


img {
max-width: 100%;
margin-bottom: 20px;
border-radius: 10px;
}

/* Section Styles */

.main-nav {
  width: 100%;
  background: black;
  min-height: 30px;
  padding: 10px;
  position: fixed;
  text-align: center;
}
.nav {
  display: flex;
  justify-content: space-around;
  font-weight: 700;
  list-style-type: none;
  margin: 0 auto;
  padding: 0;
}

.nav .name {
    display: block;
    margin-right: auto;
    color: white;
}
.nav li {
  padding: 5px 10px 10px 10px;
}
.nav a {
  transition: all .5s;
}
.nav a:hover {
  color: white;
}

header {
  text-align: center ;
  background: linear-gradient(salmon, transparent 70%),
              linear-gradient(0deg, #fff, transparent),
    salmon url('images/bitexco.jpg') no-repeat center;
  background-size:  cover;
  overflow: hidden;
  padding-top: 60px;
  border-radius: 35px;
}
header {
  line-height: 3;

}
header .profile-image {
  margin-top: 50px;
  width: 150px;
  height: 150px;
  border-radius: 50%;
  border: 3px solid white;
  box-shadow:  0 0 10px #000000;
  transition: all .5s;
}
header .profile-image:hover {
  transform: scale(1.2) rotate(5deg);
} 

.tag  {
  color: white;
  text-shadow: 0 3px 2px rgba(0,0,0, .8);
  padding: 10px;
  margin: 10px; 
  font-size: 100px;
  line-height: 1; 
} 

.image1 {
border-radius: 10%;
box-shadow:  0 0 10px #000000;
width: 500px;
}

.image3 {
border-radius: 10%;
box-shadow:  0 0 10px #000000;
width: 500px;
}

.location {
  color: white;
  font-size: 50px;
  text-shadow: 0 3px 2px rgba(0,0,0, .8);
}

.line {
 font-size: 25px; 
 opacity: .5;
}

.spanish {
 font-size: 25px; 
 opacity: .5;
}
.card {
  margin: 34px;
  text-shadow: 0 1px 1px rgba(0,0,0, .8);
  padding: 20px 40px;
  max-width: 500px;
  text-align: left;
  border-bottom: 4px solid #ccc;
  border-radius: 20px;
  transition: all .5s;
  background: linear-gradient(transparent, salmon);
  box-shadow: rgba(0,0,0, .5);  
}

.card:hover {
  border-color: #ff99ff;
}

ul.skills {
  padding: 5px 10px;
  text-align: center;
}

.skills li {
  border-radius: 6px;
  display: inline-flex;
  background: #9ae691;
  color: white;
  padding: 5px 10px;
  margin: 2px;
  box-shadow:  0 0 3px #000000;
}

.skills li:nth-child(odd) {
  background: #9de1e6;
}

footer {
  width: 100%;
  min-height: 30px;
  padding: 20px 0 40px 20px;
}

footer .copyright {
  top: -8px;
  font-size: .75em;
}

footer ul {
  list-style-type: none;
  margin: 0;
  padding: 0;
}

footer ul li {
  display: inline-block;
}

a.social {
  display: inline-block;
  text-indent: -9999px;
  margin-left: 5px;
  width: 30px;
  height: 30px;
  background-size: 30px 30px;
  opacity: .4;
  transition: all .5s;
}
a.twitter {
  background-image: url(images/twitter.svg);
}

a.github {
  background-image: url(images/github.svg);
}
a.social:hover {
  opacity: 1;
}
.clearfix {
  clear: both;
}

/* Styles for larger screens */
@media screen and (min-width: 720px) {

  .flex {
      display: -ms-flexbox;      /* TWEENER - IE 10 */
      display: flex; 
      max-width: 1200px;
      -ms-flex-pack: distribute;
      justify-content: space-around;
      margin: 0 auto;
  }

  header {
    min-height: 470px;
  }

  .nav {
    max-width: 1200px;
    padding: 0 30px;
  }


  main {
    padding-top: 20px;
  }

  main p {
    line-height: 1.6em;
  }

  footer {
    font-size: 1.3em;
    max-width: 1200px;
    margin: 40px auto;
  }

}
Sean Lopez
Sean Lopez
6,783 Points

The main issue is that it does not work Internet Explorer, but works on Chrome and Firefox.

Any feedback would be great.

Thanks,

Sean

3 Answers

Mike Hickman
Mike Hickman
19,817 Points

Hi Sean,

I'm on my way out the door, but your <head> tag is still open. Try closing it before <body> and see if IE gives it some love.

Good luck!

Mike

Sean Lopez
Sean Lopez
6,783 Points

Thanks Mike. I can't believe I missed that, but still no go with IE.

https://teamtreehouse.com/workspaces/23513852

Mike Hickman
Mike Hickman
19,817 Points

No problem.

  1. Try making it lang='en' or 'en-US' on line 2 of your html.

  2. You have an <h3> in your skills list instead of an <li>. Change that to <li> and see if it works. A great site for checking your code is https://validator.w3.org/#validate_by_input - It will show you any validation errors and warnings in your code.

Cheers!

Welcome to web development! This issue will be with you throughout your dev experience. It's called legacy development. For now you can use a site called caniuse.com here you can see what CSS is compatible with all browsers.

check to see if IE supports the HTML5 element Main.