Standards-compliant Flash and YouTube Embedding
If you’ve ever wondered why the markup provided by Flash or YouTube to embed their content don’t validate in the W3C Validating Service then you aren’t alone. Luckily for us there are developers out there who have put a lot of time and energy into creating and testing standards-compliant markup for embedding this content in your web pages. You can read more about how they came about their solutions here: Validating Flash XHTML and Validating YouTube XHTML.
Without going into the wrong way to do it, I will just post the “correct” markup below.
Validated Flash XHTML
<object type=”application/x-shockwave-flash” data=”movie.swf” width=”575″ height=”350″>
<param name=”wmode” value=”opaque” />
<param name=”movie” value=”movie.swf” />
</object>
Validated YouTube XHTML
<object type=”application/x-shockwave-flash” width=”575″ height=”350″ data=”http://www.youtube.com/v/oC4FAyg64OI&hl=en&fs=1&”>
<param name=”movie” value=”http://www.youtube.com/v/oC4FAyg64OI&hl=en&fs=1&” />
</object>
recent comments