function thisMovie(movieName)
{
	if(navigator.appName.indexOf("Microsoft") != -1)
	{
		return window[movieName];
	}
	else
	{
		return document[movieName];
	}
}

function sendEvent(typ, prm)
{
	thisMovie("audioPlayer").sendEvent(typ, prm);
}

function openPopup(href) {
	var rnd = Math.round(Math.random() * 1000);
	window.open(href, 'popup' + rnd, '');
}

function showHideLabels() {
	if(jQuery('.send2friendForm input.inText').val() != '')
	{
		jQuery('.send2friendForm input.inText').prev().addClass('hideLabel');
	};
	jQuery('.send2friendForm input.inText').focus(function()
	{
		jQuery(this).prev().addClass('hideLabel');
	});
	jQuery('.send2friendForm input.inText').blur(function()
	{
		if(jQuery(this).val() == ''){jQuery(this).prev().removeClass('hideLabel');};
	});
};

jQuery(document).ready(function() {
	showHideLabels();
	$('a.popup').click(function() {
		var href = $(this).attr('href');
		openPopup(href);
		return false;
	});
});