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

Arshdeep Singh
PLUS
Arshdeep Singh
Courses Plus Student 8,349 Points

Youtube embding not working.

Hello, I am having issue with embedding YouTube videos with embedding code. I put the code in and save the file and nothing happens. This issue is in all the browsers.

4 Answers

James Barnett
James Barnett
39,199 Points

Protocol-less URLs don't work without a web server, so in that case just add http: in front of the URL.

> The main caveat to keep in mind when using the protocol-less reference is that it will fail on pages loaded via file:/// (i.e. HTML pages you load directly from disk to your browser). So, do be sure to include the http: protocol in the URL if you happen to be developing without a web server at all, but don’t worry about omitting it otherwise.

source: http://encosia.com/3-reasons-why-you-should-let-google-host-jquery-for-you/

Could you show the code? :)

Arshdeep Singh
PLUS
Arshdeep Singh
Courses Plus Student 8,349 Points

Here is the copy of the code. Thanks

<!doctype html>

<html lang="en"> <head> <meta charset="utf-8"> <title> My Page</title> </head> <body> <p> I know how to use <abbr title="self-contained underwarter aparatus">SCUBA</abbr> gear. </p>

    <address>
        22 Rosemomt Court<br>
        Rosemont Road<br>
        W3 9LS<br>
        London
    </address>

    <p>
        My favrite book is <cite>A Tale of Two Cities</cite> by Charles Dickens.
    </p>

    <p>
        think<wbr>vitamin.com
    </p>

    <blockquote cite="http://www.html.co.uk/blockquote.html">
        <p>
            The dog was <strong><em><q>funnny</q></em></strong>.
        </p>
    </blockquote>
    <dl>
        <dt>Video Pros</dt>
        <dd>Jon</dd>
        <dd>Michael</dd>
        <dt>Teachers</dt>
        <dd>Nick</dd>
        <dd>Jim</dd>
        <dd>Amit</dd>

        <dl>
            <dt lang="en-US">Color</dt>
            <dt land="en-GB">Colour</dt>
            <dd>A sensation which (in humans) drives from the ability to detect light.</dd>
        </dl>

        <img src="">

        <object width="420" height="315"><param name="movie" value="//www.youtube.com/v/HnbMYzdjuBs?hl=en_GB&amp;version=3"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src="//www.youtube.com/v/HnbMYzdjuBs?hl=en_GB&amp;version=3" type="application/x-shockwave-flash" width="420" height="315" allowscriptaccess="always" allowfullscreen="true"></embed></object>



</body>

</html>