function getWindowWidth() {
    var myWidth = 0;
    if( typeof( window.innerWidth ) == 'number' ) {
        //Non-IE
        myWidth = window.innerWidth;
    } else if( document.documentElement && document.documentElement.clientWidth ) {
        //IE 6+ in 'standards compliant mode'
        myWidth = document.documentElement.clientWidth + 8;
    } else if( document.body && document.body.clientWidth ) {
        //IE 4 compatible
        myWidth = document.body.clientWidth;
    }
    return myWidth;
}

function closeHulk() {
    var bigHulk = document.getElementById("bigHulk");
    bigHulk.innerHTML = '';
    bigHulk.style.display = "none";
}

function openHulk() {
    var bigHulk = document.getElementById("bigHulk");
    bigHulk.style.display = "block";
    bigHulk.innerHTML = '<object id="swfbigHulk" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://active.macromedia.com/flash2/cabs/swflash.cab#version=7,0,19,0" width="966" height="681"><param name="movie" value="/partner/hulk/HULKB-966x681.swf"><param name="quality" value="high"><param name="wmode" value="transparent"><param name="allowscriptaccess" value="alway"><param name="swliveconnect" value="true"><param name="loop" value="true"><embed name="swfbigHulk" src="http://202.6.233.52/partner/media/966x681/HULKB-966x681.swf" quality="high" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash" width="966" height="681" wmode="transparent" allowscriptaccess="always" swliveconnect="true"></embed><embed name="swfbigHulk" src="/partner/hulk/HULKB-966x681.swf" quality="high" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash" width="966" height="681" wmode="transparent" allowscriptaccess="always" swliveconnect="true"></embed></object>';
}

var reff = document.location.href;
if(reff == 'http://www.kapanlagi.com/' || reff == 'http://www.kapanlagi.com/index.html' || reff == 'http://kapanlagi.com/' || reff == 'http://kapanlagi.com/index.html') {
    var bigDisplay = 'block';
} else {
    var bigDisplay = 'none';
}
var winWidth = getWindowWidth();
var browser = BrowserDetect.browser;
var version = BrowserDetect.version;
//document.write(reff);

if(browser == "Explorer")
{
    var bigHulkTop = 2;
    var bigHulkLeft = ((winWidth - 965) / 2) - 11;
}
else if(browser == "Firefox")
{
    var bigHulkTop = 0;
    var bigHulkLeft = ((winWidth - 966) / 2) - 15;
}
else if(browser == "Opera")
{
    var bigHulkTop = 0;
    var bigHulkLeft = ((winWidth - 965) / 2) - 15;
}
else if(browser == "Safari")
{
    var bigHulkTop = 0;
    var bigHulkLeft = ((winWidth - 966) / 2) - 14;
}
else if(browser == "Chrome")
{
    var bigHulkTop = 0;
    var bigHulkLeft = ((winWidth - 966) / 2) - 15;
}

document.write('<div id="bigHulk" style="z-index:1; width:966px;height:681px;position:absolute;top:' + bigHulkTop + 'px;left:' + bigHulkLeft + 'px;display:' + bigDisplay + ';">');
document.write('  <object id="swfbigHulk" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://active.macromedia.com/flash2/cabs/swflash.cab#version=7,0,19,0" width="966" height="681">');
document.write('    <param name="movie" value="/partner/hulk/HULKB-966x681.swf">');
document.write('    <param name="quality" value="high">');
document.write('    <param name="wmode" value="transparent">');
document.write('    <param name="allowscriptaccess" value="alway">');
document.write('    <param name="swliveconnect" value="true">');
document.write('    <param name="loop" value="true">');
document.write('    <embed name="swfbigHulk" src="/partner/hulk/HULKB-966x681.swf" quality="high" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash" width="966" height="681" wmode="transparent" allowscriptaccess="always" swliveconnect="true"></embed>');
document.write('  </object>');
document.write('</div>');
