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 HTML Objects Embedded Elements

embedded code is marked as error in workspace.

<html lang="en">
<head>
  <meta charset="utf-8">
  <title>My Page</title>
</head>
<body>
<object width="560" height="315">
  <param name="movie" value="//www.youtube.com/v/P8LBvJ83g94?version=3&amp;hl=en_US"></param>
  <param name="allowFullScreen" value="true"></param>
  <param name="allowscriptaccess" value="always"></param>
<embed src="//www.youtube.com/v/P8LBvJ83g94?version=3&amp;hl=en_US" type="application/x-shockwave-flash" width="560" height="315" allowscriptaccess="always" allowfullscreen="true"></embed>
</object>
</body>
</html>

the workspace highlights in red on /param, /object, /body, and /html

Anybody has any idea?

3 Answers

I honestly after reviewing that section just think its because it is the old embed code youtube used. It was a combination of ie params and a embed code for other browsers. When I use the new youtube embedcode such as the one used below I dont get that error in workspace. Also Nick says at the end of the video that the code your using really shouldnt be used any more however if you are forced to work with it , that info is a good point of reference. Hope that helps solve any issues and concerns maybe we will get Nick Pettit to help us explain if this is the reason why you have that error.

<!DOCTYPE html>
<html lang="en">
  <head>
     <meta charset="utf-8">
     <title>My Page</title>
  </head>
   <body>
      <div><iframe width="560" height="315" src="//www.youtube.com/embed/r9BHLaXoTVw" frameborder="0" allowfullscreen></iframe>
      </div>
   </body>
</html>
Nick Pettit
STAFF
Nick Pettit
Treehouse Teacher

Hi everyone,

Not sure what the issue is here, but I'll pass it along to the Workspaces team so they can take a look!

I am so excited my own teacher can reply me!! Hey, Nick Pettit , I like your way of teaching, you make things clear and simple!

Add http: before the youtube links.......

Thanks for your answer, but the red highlight is still there after I put http: in the link, any idea why?

James Barnett
James Barnett
39,199 Points

That's only an issue if you are developing locally without a web server, which is not the case if you are using Workspaces.