//joybase.js
var JoySpaceUrl = "http://space.you.joy.cn/";
function killErrors() {
    return true;
}
window.onerror = killErrors;
jQuery.cookie = function(name, value, options) {
    if (typeof value != 'undefined') { // name and value given, set cookie
        options = options || {};
        if (value === null) {
            value = '';
            options.expires = -1;
        }
        var expires = '';
        if (options.expires && (typeof options.expires == 'number' || options.expires.toUTCString)) {
            var date;
            if (typeof options.expires == 'number') {
                date = new Date();
                date.setTime(date.getTime() + (options.expires * 24 * 60 * 60 * 1000));
            } else {
                date = options.expires;
            }
            expires = '; expires=' + date.toUTCString(); // use expires attribute, max-age is not supported by IE
        }
        // CAUTION: Needed to parenthesize options.path and options.domain
        // in the following expressions, otherwise they evaluate to undefined
        // in the packed version for some reason...
        var path = options.path ? '; path=' + (options.path) : '';
        var domain = options.domain ? '; domain=' + (options.domain) : '';
        var secure = options.secure ? '; secure' : '';
        document.cookie = [name, '=', encodeURIComponent(value), expires, path, domain, secure].join('');
    } else { // only name given, get cookie
        var cookieValue = null;
        if (document.cookie && document.cookie != '') {
            var cookies = document.cookie.split(';');
            for (var i = 0; i < cookies.length; i++) {
                var cookie = jQuery.trim(cookies[i]);
                // Does this cookie string begin with the name we want?
                if (cookie.substring(0, name.length + 1) == (name + '=')) {
                    cookieValue = decodeURIComponent(cookie.substring(name.length + 1));
                    break;
                }
            }
        }
        return cookieValue;
    }
};

jQuery.fn.extend({
    Opacity : function(value){
        return this.each(function(){
            if(value!=null)
            {
                if ( $.browser.msie ){
                    this.style.filter = "alpha(opacity = "+value+")";
                }
                else{
                    this.style.MozOpacity = parseInt(value)/100;
                }
            }
        })
    }
})

jQuery.fn.offset = function() {
    var ua = navigator.userAgent.toLowerCase();
    var isOpera = (ua.indexOf('opera') != -1);
    var isIE = (ua.indexOf('msie') != -1 && !isOpera); // not opera spoof
    var el = this[0];
    if(el.parentNode === null || el.style.display == 'none')
    {
        return false;
    }
    var parent = null;
    var pos = [];
    var box;
    
    if(el.getBoundingClientRect) //IE
    {
        box = el.getBoundingClientRect();
        var scrollTop = Math.max(document.documentElement.scrollTop, document.body.scrollTop);
        var scrollLeft = Math.max(document.documentElement.scrollLeft, document.body.scrollLeft);
        return {left:box.left + scrollLeft, top:box.top + scrollTop};
    }
    else if(document.getBoxObjectFor) // gecko
    {
        box = document.getBoxObjectFor(el);
        var borderLeft = (el.style.borderLeftWidth)?parseInt(el.style.borderLeftWidth):0;
        var borderTop = (el.style.borderTopWidth)?parseInt(el.style.borderTopWidth):0;
        pos = [box.x - borderLeft, box.y - borderTop];
    }
    else // safari & opera
    {
        pos = [el.offsetLeft, el.offsetTop];
        parent = el.offsetParent;
        if (parent != el)
        {
            while (parent) {
                pos[0] += parent.offsetLeft;
                pos[1] += parent.offsetTop;
                parent = parent.offsetParent;
            }
        
        }
        if (ua.indexOf('opera') != -1
        || ( ua.indexOf('safari') != -1 && el.style.position == 'absolute' ))
        {
            pos[0] -= document.body.offsetLeft;
            pos[1] -= document.body.offsetTop;
        }
    }
    if (el.parentNode) { parent = el.parentNode; }
    else { parent = null; }
    while (parent && parent.tagName != 'BODY' && parent.tagName != 'HTML')
    { // account for any scrolled ancestors
        pos[0] -= parent.scrollLeft;
        pos[1] -= parent.scrollTop;
        if (parent.parentNode) { parent = parent.parentNode; }
        else { parent = null; }
    }
    return {left:pos[0], top:pos[1]}; 
};

jQuery.ByteLen=function(str)
{
    return str.replace(/[^\x00-\xff]/g,"**").length;
};

jQuery.FixTitle=function(str,len)
{
    if($.ByteLen(str)>=(len*2-6))
    {
        if($.ByteLen(str)>str.length)
        {
            return str.substring(0,len);
        }
        return str.substring(0,(len*2-6));
    }
    return str;
};


//playerbag.js
function ShowPlayer(vId,fileName,type, xyid, xyaid, key)//
{
    if(key != '')
    {
        if(type=="media")
        {
           writeMegadiaPlaer(fileName);
        }
        else if(type=="flv")
        {
           writeFL(vId, xyid, xyaid, key);
        }
        else if(type=="real")
        {
            writeRealPlayer(fileName)
        }
        else
        {
            writeMegadiaPlaer(fileName);
        }
    }
    else
    {
	    if(type=="media")
	    {
	       writeMegadiaPlaer(fileName);
	    }
	    else if(type=="flv")
	    {
	       writeFL(vId);
	    }
	    else if(type=="photoplay")
	    {
	        writePhotoPlayer(vId);
	    }
	    else if(type=="real")
	    {
            writeRealPlayer(fileName)
	    }
	    else
	    {
            writeMegadiaPlaer(fileName);
	    }
	}
}


function writeRealPlayer(filePath)
{

    document.writeln('<object classid=clsid:CFCDAA03-8BE4-11cf-B84B-0020AFBBCCFA height="367" id=RAOCX name=rmplay width="460"> ');
    document.writeln('<param name="SRC" value="'+filePath+'">');
    document.writeln('<param name="CONSOLE" value="Clip1">');
    document.writeln('<param name="CONTROLS" value="imagewindow">');
    document.writeln('<param name="AUTOSTART" value="true">');
    document.writeln('<embed src="'+filePath+'" autostart="true" controls="ImageWindow" console="Clip1" pluginspage="http://www.real.com" width="460" height="367"></embed>');
 	document.writeln('<object classid="clsid:CFCDAA03-8BE4-11cf-B84B-0020AFBBCCFA" height="54" id="video1" width="460">');
	document.writeln('<param name="_ExtentX" value="7276">');
	document.writeln('<param name="_ExtentY" value="1058">');
	document.writeln('<param name="AUTOSTART" value="0">');
	document.writeln('<param name="SHUFFLE" value="0">');
	document.writeln('<param name="PREFETCH" value="0">');
	document.writeln('<param name="NOLABELS" value="0">');
	document.writeln('<param name="CONTROLS" value="ControlPanel,StatusBar">');
	document.writeln('<param name="CONSOLE" value="Clip1">');
	document.writeln('<param name="LOOP" value="0">');
	document.writeln('<param name="NUMLOOP" value="0">');
	document.writeln('<param name="CENTER" value="0">');
	document.writeln('<param name="MAINTAINASPECT" value="0">');
	document.writeln('<param name="BACKGROUNDCOLOR" value="#ffffff">');
	document.writeln('<embed type="audio/x-pn-realaudio-plugin" console="Clip1" controls="ControlPanel,StatusBar" height="54" width="460" autostart="0" _extentx="7276" _extenty="1058" shuffle="0" prefetch="0" nolabels="0" loop="0" numloop="0" center="0" maintainaspect="0" backgroundcolor="#ffffff"></embed>');
	document.writeln('</object>');
}


function writeMegadiaPlaer(filepath)
{
	document.writeln('<object classid="clsid:22D6F312-B0F6-11D0-94AB-0080C74C7E95" width="460" height="391" id="MediaPlayer1" VIEWASTEXT>');
	document.writeln('<param name="AudioStream" value="-1">');
	document.writeln('<param name="AutoSize" value="0">');
	document.writeln('<param name="AutoStart" value="-1">');
	document.writeln('<param name="AnimationAtStart" value="-1">');
	document.writeln('<param name="AllowScan" value="-1">');
	document.writeln('<param name="AllowChangeDisplaySize" value="-1">');
	document.writeln('<param name="AutoRewind" value="0">');
	document.writeln('<param name="Balance" value="0">');
	document.writeln('<param name="BaseURL" value>');
	document.writeln('<param name="BufferingTime" value="15">');
	document.writeln('<param name="CaptioningID" value>');
	document.writeln('<param name="ClickToPlay" value="-1">');
	document.writeln('<param name="CursorType" value="0">');
	document.writeln('<param name="CurrentPosition" value="0">');
	document.writeln('<param name="CurrentMarker" value="0">');
	document.writeln('<param name="DefaultFrame" value>');
	document.writeln('<param name="DisplayBackColor" value="#000000">');
	document.writeln('<param name="DisplayForeColor" value="16777215">');
	document.writeln('<param name="DisplayMode" value="0">');
	document.writeln('<param name="DisplaySize" value="0">');
	document.writeln('<param name="Enabled" value="-1">');
	document.writeln('<param name="EnableContextMenu" value="0">');
	document.writeln('<param name="EnablePositionControls" value="-1">');
	document.writeln('<param name="EnableFullScreenControls" value="-1">');
	document.writeln('<param name="EnableTracker" value="-1">');
	document.writeln('<param name="Filename" value="' + filepath+ '" valuetype="ref">');
	document.writeln('<param name="InvokeURLs" value="-1">');
	document.writeln('<param name="Language" value="-1">');
	document.writeln('<param name="Mute" value="0">');
	document.writeln('<param name="PlayCount" value="1">');
	document.writeln('<param name="PreviewMode" value="-1">');
	document.writeln('<param name="Rate" value="1">');
	document.writeln('<param name="SAMIStyle" value>');
	document.writeln('<param name="SAMILang" value>');
	document.writeln('<param name="SAMIFilename" value>');
	document.writeln('<param name="SelectionStart" value="-1">');
	document.writeln('<param name="SelectionEnd" value="-1">');
	document.writeln('<param name="SendOpenStateChangeEvents" value="-1">');
	document.writeln('<param name="SendWarningEvents" value="-1">');
	document.writeln('<param name="SendErrorEvents" value="-1">');
	document.writeln('<param name="SendKeyboardEvents" value="0">');
	document.writeln('<param name="SendMouseClickEvents" value="0">');
	document.writeln('<param name="SendMouseMoveEvents" value="0">');
	document.writeln('<param name="SendPlayStateChangeEvents" value="-1">');
	document.writeln('<param name="ShowCaptioning" value="0">');
	document.writeln('<param name="ShowControls" value="-1">');
	document.writeln('<param name="ShowAudioControls" value="-1">');
	document.writeln('<param name="ShowDisplay" value="0">');
	document.writeln('<param name="ShowGotoBar" value="0">');
	document.writeln('<param name="ShowPositionControls" value="-1">');
	document.writeln('<param name="ShowStatusBar" value="-1">');
	document.writeln('<param name="ShowTracker" value="-1">');
	document.writeln('<param name="TransparentAtStart" value="-1">');
	document.writeln('<param name="VideoBorderWidth" value="0">');
	document.writeln('<param name="VideoBorderColor" value="0">');
	document.writeln('<param name="VideoBorder3D" value="0">');
	document.writeln('<param name="Volume" value="0">');
	document.writeln('<param name="WindowlessVideo" value="0">');
	document.writeln('<embed width="460" height="391" type="application/x-mplayer2" src="' + filepath+ '"></embed>')
	document.writeln('</object>');

}

function getKanBaParam()
{
	try
	{
		var url = location.href;
		var m = url.match(/video\/(\d+_[^_]+(?:_\d+)+)\.htm/i);
		if (m != null)
		{
			if (m.length > 1)
			{
				var pm = '';
				var p = m[1].split('_');
				return p;
			}
		}
	}
	catch (e)
	{
	}
	return '[]';
}
function writeFL(vid)//videoId, xyid, xyaid, key
{
	var _Vkb = ['action', 'tid', 'pid', 'starttime']; //çœ‹å§å‚æ•°å?
	var _Vxy = ['xyid', 'sharemode', 'xkey']; //å¿ƒè¯­å‚æ•°å?
	var _Akb = getKanBaParam(); //èŽ·å–çœ‹å§å‚æ•°å€?ä»Žåœ°å€ä¸?
    var _Axy = arguments; //èŽ·å–å¿ƒè¯­å‚æ•°å€?ä»Žå‚æ•°è¡¨ä¸­å–)

	var flash = new SWFObject("http://client.joy.cn/flvplayer/BagPlayer_V3.swf?jname=setPlayerFront", "myplayer", "825", "460", "9", "#00000");
	flash.addParam("allowFullScreen", "true");
	flash.addParam("allowScriptAccess", "always");
	flash.addParam("quality", "high");
	flash.addParam("wmode", "Transparent");
	flash.addVariable('strvid', vid);
	//æ·»åŠ çœ‹å§å‚æ•°
	for (var i = 0; i < _Vkb.length; i ++)
	{
		if (_Akb.length > i + 1) flash.addVariable(_Vkb[i], _Akb[i + 1]);
	}
	//æ·»åŠ å¿ƒè¯­å‚æ•°
	for (var i = 0; i < _Vxy.length; i ++)
	{
		if (_Axy.length > i + 1) flash.addVariable(_Vxy[i], _Axy[i + 1]);
	}
	//realé¢‘é“417322è§†é¢‘åŠ å¹¿å‘?60
	if (location.hostname.toLowerCase() == 'real.joy.cn' && vid == 417322)
	{
		flash.addVariable('adpid', 360);
	}
	flash.write("dplayer");
}
//å‰ç½®æ’­æ”¾å™¨é¿å…è¦†ç›–å³ä¾§æ 
function setPlayerFront(playerfront)
{
	var rc = document.getElementById("rightcolumn");
	if (rc) {
		if (playerfront == 'true')
		{
			rc.style.position =  'static';
		}
		else
		{
			rc.style.position =  'relative';
		}
	}
}
function writePhotoPlayer(vId)
{
    	document.writeln('<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0" width="480" height="385">');
	    document.writeln('<param name="movie" value="http://client.joy.cn/flvplayer/AlbumPlayer.swf?strvid='+vId+'&autoplay=true" />');
	    document.writeln('<param name="allowFullScreen" value="true" />');
	    document.writeln('<param name="quality" value="high" />');
	    document.writeln('<param name="wmode" value="opaque" />');
	    document.writeln('<embed src="http://client.joy.cn/flvplayer/AlbumPlayer.swf?strvid='+vId+'&autoplay=true" allowfullscreen="true" wmode="opaque" width="480" height="385" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash"></embed></object>');

}

//megajoyplay.js

/**
 * SWFObject v1.5: Flash Player detection and embed - http://blog.deconcept.com/swfobject/
 *
 * SWFObject is (c) 2007 Geoff Stearns and is released under the MIT License:
 * http://www.opensource.org/licenses/mit-license.php
 *
 */
if(typeof deconcept == "undefined") var deconcept = new Object();
if(typeof deconcept.util == "undefined") deconcept.util = new Object();
if(typeof deconcept.SWFObjectUtil == "undefined") deconcept.SWFObjectUtil = new Object();
deconcept.SWFObject = function(swf, id, w, h, ver, c, quality, xiRedirectUrl, redirectUrl, detectKey) {
	if (!document.getElementById) { return; }
	this.DETECT_KEY = detectKey ? detectKey : 'detectflash';
	this.skipDetect = deconcept.util.getRequestParameter(this.DETECT_KEY);
	this.params = new Object();
	this.variables = new Object();
	this.attributes = new Array();
	if(swf) { this.setAttribute('swf', swf); }
	if(id) { this.setAttribute('id', id); }
	if(w) { this.setAttribute('width', w); }
	if(h) { this.setAttribute('height', h); }
	if(ver) { this.setAttribute('version', new deconcept.PlayerVersion(ver.toString().split("."))); }
	this.installedVer = deconcept.SWFObjectUtil.getPlayerVersion();
	if (!window.opera && document.all && this.installedVer.major > 7) {
		// only add the onunload cleanup if the Flash Player version supports External Interface and we are in IE
		deconcept.SWFObject.doPrepUnload = true;
	}
	if(c) { this.addParam('bgcolor', c); }
	var q = quality ? quality : 'high';
	this.addParam('quality', q);
	this.setAttribute('useExpressInstall', false);
	this.setAttribute('doExpressInstall', false);
	var xir = (xiRedirectUrl) ? xiRedirectUrl : window.location;
	this.setAttribute('xiRedirectUrl', xir);
	this.setAttribute('redirectUrl', '');
	if(redirectUrl) { this.setAttribute('redirectUrl', redirectUrl); }
}
deconcept.SWFObject.prototype = {
	useExpressInstall: function(path) {
		this.xiSWFPath = !path ? "expressinstall.swf" : path;
		this.setAttribute('useExpressInstall', true);
	},
	setAttribute: function(name, value){
		this.attributes[name] = value;
	},
	getAttribute: function(name){
		return this.attributes[name];
	},
	addParam: function(name, value){
		this.params[name] = value;
	},
	getParams: function(){
		return this.params;
	},
	addVariable: function(name, value){
		this.variables[name] = value;
	},
	getVariable: function(name){
		return this.variables[name];
	},
	getVariables: function(){
		return this.variables;
	},
	getVariablePairs: function(){
		var variablePairs = new Array();
		var key;
		var variables = this.getVariables();
		for(key in variables){
			variablePairs[variablePairs.length] = key +"="+ variables[key];
		}
		return variablePairs;
	},
	getSWFHTML: function() {
		var swfNode = "";
		if (navigator.plugins && navigator.mimeTypes && navigator.mimeTypes.length) { // netscape plugin architecture
			if (this.getAttribute("doExpressInstall")) {
				this.addVariable("MMplayerType", "PlugIn");
				this.setAttribute('swf', this.xiSWFPath);
			}
			swfNode = '<embed pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" src="'+ this.getAttribute('swf') +'" width="'+ this.getAttribute('width') +'" height="'+ this.getAttribute('height') +'" style="'+ this.getAttribute('style') +'"';
			swfNode += ' id="'+ this.getAttribute('id') +'" name="'+ this.getAttribute('id') +'" ';
			var params = this.getParams();
			 for(var key in params){ swfNode += [key] +'="'+ params[key] +'" '; }
			var pairs = this.getVariablePairs().join("&");
			 if (pairs.length > 0){ swfNode += 'flashvars='+ pairs +'&realfull=1&moz=1"'; }
			swfNode += '/>';
		} else { // PC IE
			if (this.getAttribute("doExpressInstall")) {
				this.addVariable("MMplayerType", "ActiveX");
				this.setAttribute('swf', this.xiSWFPath);
			}
			swfNode = '<object id="'+ this.getAttribute('id') +'" classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,115,0" width="'+ this.getAttribute('width') +'" height="'+ this.getAttribute('height') +'" style="'+ this.getAttribute('style') +'">';
			swfNode += '<param name="movie" value="'+ this.getAttribute('swf') +'" />';
			var params = this.getParams();
			for(var key in params) {
			 swfNode += '<param name="'+ key +'" value="'+ params[key] +'" />';
			}
			var pairs = this.getVariablePairs().join("&");
			if(pairs.length > 0) {swfNode += '<param name="flashvars" value="'+ pairs +'" />';}
			swfNode += "</object>";
		}
		return swfNode;
	},
	write: function(elementId){
		if(this.getAttribute('useExpressInstall')) {
			// check to see if we need to do an express install
			var expressInstallReqVer = new deconcept.PlayerVersion([6,0,65]);
			if (this.installedVer.versionIsValid(expressInstallReqVer) && !this.installedVer.versionIsValid(this.getAttribute('version'))) {
				this.setAttribute('doExpressInstall', true);
				this.addVariable("MMredirectURL", escape(this.getAttribute('xiRedirectUrl')));
				document.title = document.title.slice(0, 47) + " - Flash Player Installation";
				this.addVariable("MMdoctitle", document.title);
			}
		}
		if(this.skipDetect || this.getAttribute('doExpressInstall') || this.installedVer.versionIsValid(this.getAttribute('version'))){
			
		}else{
			if(this.getAttribute('redirectUrl') != "") {
				document.location.replace(this.getAttribute('redirectUrl'));
			}
			
		}
		var n = (typeof elementId == 'string') ? document.getElementById(elementId) : elementId;
		n.innerHTML = this.getSWFHTML();
		return true;
	}
}

/* ---- detection functions ---- */
deconcept.SWFObjectUtil.getPlayerVersion = function(){
	var PlayerVersion = new deconcept.PlayerVersion([0,0,0]);
	if(navigator.plugins && navigator.mimeTypes.length){
		var x = navigator.plugins["Shockwave Flash"];
		if(x && x.description) {
			PlayerVersion = new deconcept.PlayerVersion(x.description.replace(/([a-zA-Z]|\s)+/, "").replace(/(\s+r|\s+b[0-9]+)/, ".").split("."));
		}
	}else if (navigator.userAgent && navigator.userAgent.indexOf("Windows CE") >= 0){ // if Windows CE
		var axo = 1;
		var counter = 3;
		while(axo) {
			try {
				counter++;
				axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash."+ counter);
//				document.write("player v: "+ counter);
				PlayerVersion = new deconcept.PlayerVersion([counter,0,0]);
			} catch (e) {
				axo = null;
			}
		}
	} else { // Win IE (non mobile)
		// do minor version lookup in IE, but avoid fp6 crashing issues
		// see http://blog.deconcept.com/2006/01/11/getvariable-setvariable-crash-internet-explorer-flash-6/
		try{
			var axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash.7");
		}catch(e){
			try {
				var axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash.6");
				PlayerVersion = new deconcept.PlayerVersion([6,0,21]);
				axo.AllowScriptAccess = "always"; // error if player version < 6.0.47 (thanks to Michael Williams @ Adobe for this code)
			} catch(e) {
				if (PlayerVersion.major == 6) {
					return PlayerVersion;
				}
			}
			try {
				axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash");
			} catch(e) {}
		}
		if (axo != null) {
			PlayerVersion = new deconcept.PlayerVersion(axo.GetVariable("$version").split(" ")[1].split(","));
		}
	}
	return PlayerVersion;
}
deconcept.PlayerVersion = function(arrVersion){
	this.major = arrVersion[0] != null ? parseInt(arrVersion[0]) : 0;
	this.minor = arrVersion[1] != null ? parseInt(arrVersion[1]) : 0;
	this.rev = arrVersion[2] != null ? parseInt(arrVersion[2]) : 0;
}
deconcept.PlayerVersion.prototype.versionIsValid = function(fv){
	if(this.major < fv.major) return false;
	if(this.major > fv.major) return true;
	if(this.minor < fv.minor) return false;
	if(this.minor > fv.minor) return true;
	if(this.rev < fv.rev) return false;
	return true;
}
/* ---- get value of query string param ---- */
deconcept.util = {
	getRequestParameter: function(param) {
		var q = document.location.search || document.location.hash;
		if (param == null) { return q; }
		if(q) {
			var pairs = q.substring(1).split("&");
			for (var i=0; i < pairs.length; i++) {
				if (pairs[i].substring(0, pairs[i].indexOf("=")) == param) {
					return pairs[i].substring((pairs[i].indexOf("=")+1));
				}
			}
		}
		return "";
	}
}
/* fix for video streaming bug */
deconcept.SWFObjectUtil.cleanupSWFs = function() {
	var objects = document.getElementsByTagName("OBJECT");
	for (var i = objects.length - 1; i >= 0; i--) {
		objects[i].style.display = 'none';
		for (var x in objects[i]) {
			if (typeof objects[i][x] == 'function') {
				objects[i][x] = function(){};
			}
		}
	}
}
// fixes bug in some fp9 versions see http://blog.deconcept.com/2006/07/28/swfobject-143-released/
if (deconcept.SWFObject.doPrepUnload) {
	if (!deconcept.unloadSet) {
		deconcept.SWFObjectUtil.prepUnload = function() {
			__flash_unloadHandler = function(){};
			__flash_savedUnloadHandler = function(){};
			window.attachEvent("onunload", deconcept.SWFObjectUtil.cleanupSWFs);
		}
		window.attachEvent("onbeforeunload", deconcept.SWFObjectUtil.prepUnload);
		deconcept.unloadSet = true;
	}
}
/* add document.getElementById if needed (mobile IE < 5) */
if (!document.getElementById && document.all) { document.getElementById = function(id) { return document.all[id]; }}

/* add some aliases for ease of use/backwards compatibility */
var getQueryParamValue = deconcept.util.getRequestParameter;
var FlashObject = deconcept.SWFObject; // for legacy support
var SWFObject = deconcept.SWFObject;

//news add

function holdPlayer()
{
	try
	{
		var o = $("#flash").offset();
	    $("#dplayer").css({'top':o.top - 35,'left':o.left,'display':''});
	}
	catch(e)
    {
	}
}

//showplay1.js

var xpos,ypos,locationobj;

function showBtn(obj,url){
	var scrox = document.documentElement.scrollLeft;
	var scroy = document.documentElement.scrollTop;
	//alert(scrox );
	getAbsPoint(obj);
	locationobj = url;
	document.getElementById("btn1").style.display = 'block';
	document.getElementById("btn1").style.left = xpos+scrox+25+"px";
	document.getElementById("btn1").style.top = ypos+scroy+15+"px";
}
function showBtn1(obj,url){
	//var scrox = document.documentElement.scrollLeft;
	//var scroy = document.documentElement.scrollTop;
	//alert(scrox );
	//getAbsPoint(obj);
	//locationobj = url;
	//document.getElementById("btn1").style.display = 'block';
	//document.getElementById("btn1").style.left = xpos+scrox+25+"px";
	//document.getElementById("btn1").style.top = ypos+scroy+15+"px";
}
function hiddnBtn(){
	//document.getElementById("btn1").style.display = 'none';
}

function openPage(){
	//window.location.href=locationobj;
}

function showContinue(obj){
	//obj.style.display = 'block';
}

function getAbsPoint(obj){   
    var oRect = obj.getBoundingClientRect();  
	xpos=oRect.left   
	ypos=oRect.top  
}