// Begin MultiLayoutRegions
$(document).ready(
function() {
	$('#MultiLayoutRegion3LYR').MyTab({ selected: 0, event: 'click', fx: {opacity: 'toggle', duration: 'fast'} });
}
);
// End MultiLayoutRegions

// Begin XHTML adjustment
$(document).ready(function(){
	if (jQuery.browser.msie && jQuery.browser.version.substr(0, 2) == "6.") {
		$(".nof-clearfix").each(function (i) {
			$(this).append("<div style='clear:both'/>");
			$(this).removeClass("nof-clearfix");
		});
	}
	if (jQuery.browser.safari){
		$(".nof-lyr>br:first").each(function () {
			$(this).replaceWith("<div style='height:0px'>&nbsp;</div>");
		});
	}
});

// End XHTML adjustment

// Begin jMedia Components
$(document).ready(
function() {
	$("#Flash1").media({
	width: '92%', src: 'http://vzaar.com/videos/607357.swf', flashVersion: '5,0,0,0',
		autoplay: true,
 	params: { loop: 'false', quality: 'autolow', scale: 'noborder', salign: 'Center', wmode: 'transparent' }
	});
});
// End jMedia Components


// JC code
////////////////////////////////////////////////
function PlayFlashVideoLocal(videourl, w, h)
{

var source = videourl;

$("#Flash1").media({
			 width: w, height: h, src: source , flashVersion: '5,0,0,0', 
autoplay: true, 
			 params: {
			 loop: 'false', quality: 'autolow', scale: 'noborder', salign: 'Center', wmode: 'transparent' 
				 }
		     });



}


function PlayFlashVideoExternal(videourl, w, h)
{

$("#Flash1").html('<object id="video" width="' + w + '" height="' + h + '" type="application/x-shockwave-flash" data=' + videourl
       + '><param name="movie" value=' + videourl + '><param name="scale" value="noborder"><param name="allowScriptAccess" value="always"><param name="allowFullScreen" value="true"><param name="movie" value=' + videourl 
       + '><param name="wmode" value="transparent"><param name="flashvars" value="brandText=Farrell Hair Replacement&border=none&brandLink=www.farrellhair.com&colourSet=brown&autoplay=true"><embed src=' + videourl
       + ' type="application/x-shockwave-flash" wmode="transparent" width="' + w + '" height="' + h + '" scale="noborder" allowScriptAccess="always" allowFullScreen="true" flashvars="brandText=Farrell Hair Replacement&border=none&brandLink=www.farrellhair.com&colourSet=brown&autoplay=true"></embed><video width="' + w + '" height="' + h + '"  poster=' + videourl
       +'.frame ></video></object>');


}
///////////////////////////////////////////
