function embedVideo(filename, path, topic, width, height, version) {

	// Default values.
	width   = typeof(width)   != 'undefined' ? width   : 566;
	height  = typeof(height)  != 'undefined' ? height  : 424;
	version = typeof(version) != 'undefined' ? version : '8';

	var url = 'https://s3.amazonaws.com/media.infoforpatients.com/';

	// The site might already use Modernizr, so check before loading it.
	if (typeof(Modernizr) == 'undefined')
		document.write('<script type="text/javascript" src="' + path + '_common/modernizr-1.5.min.js"></scr' + 'ipt>');

	// Use the HTML5 video tag to play the H.264 video if the browser supports it.
	if (Modernizr.video && Modernizr.video.h264) {

		jQuery('#player').html('<video src="' + url + filename + '" controls="controls" autoplay="autoplay" width="' + width + '" height="' + height + '" />');

	// Otherwise, use the flash player.
	} else {

		swfobject.embedSWF(
			path + '_common/player.swf',
			'player',
			width,
			height,
			version,
			false,
			{
				file:url+filename,
				autostart:true,
				backcolor:'333333',
				frontcolor:'dae7f2',
				lightcolor:'dae7f2'
			},
			{ allowfullscreen:true }
		);
	}
}
