The following snippet shows the HDFlashPlayer embeding a YouTube video into HTML using the FlashVars. It assumes the the flash player is located in hdflvplayer/hdplayer.swf relative to the page where this script is going to be run from.

<div name='mediaspace' id='mediaspace'>

<script type="text/javascript">

var s1 = new SWFObject('hdflvplayer/hdplayer.swf', 'player', '640', '360', '9');

s1.addParam('allowfullscreen', 'true');

s1.addParam('allowscriptaccess', 'always');

s1.addParam('wmode', 'transparent');

// example :

s1.addVariable('file', 'youtube page url goes here');