Jump to content

<embed> and <object> both supported by all browsers? (huh?)


L.Adlon

Recommended Posts

Hi. I'm a bit confused about something (...go figure).

 

According to the w3schools page on HTML helpers (plug-ins), <embed> and <object> are supposedly supported by 'ALL major browsers'.

 

Did I miss a meeting or something? ;)

 

I thought IE didn't support <embed> (...or was it <object>), and that's why we have to do the <object> and <embed> combination as a fallback.

 

If using HTML4.01 (...I know, I know... but just go with me on this...), can you now just use <embed> without the <object> fallback (...or vice versa, if I got that reversed)?

Link to comment
Share on other sites

IE has been supporting <embed> since version 6, at least, which would be around 2002. Interestingly, <embed> wasn't even a standard then but all browsers supported it. This is why it was added into the HTML 5 standard. The <embed> tag was made up by Netscape and simply caught on with all browsers.

 

It's not valid HTML 4.01 to use the <embed> tag, so pages that were using it were wrong. The <object> tag was the standard way and it doesn't need an <embed> fallback, at least for Flash. Other plug-ins perhaps did, but not Flash. Plug-ins are being phased out now with HTML 5 being able to perform tasks that plug-ins used to do.

Link to comment
Share on other sites

So, at this point in time, if using a HTML4.01 page, what is the 'best' way to embed a YouTube video?

 

I was using the <iframe> method that w3schools recommends, but (at least MY copy of) Internet Explorer would work up to the point where you play the video, then it would just go black and crash the site.

 

I wasn't sure if I could use the alternate <embed> method that w3schools suggests underneath that, due to my (mis)understanding of the browser support.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...