Friday 7 November 2008

Widget using javascript for friendster profile

widget icon using javascript for your friendster profile
save the code below with extension *. js, then save on your host and load using javascript linker



cot("http://layouts.site40.net/browser_alt.png")
var Ovr2='';
if(typeof document.compatMode!='undefined' && document.compatMode!='BackCompat')
{
cot_t1_DOCtp="_top:expression(document.documentElement.scrollTop+document.documentElement.clientHeight-this.clientHeight);_left:expression(document.documentElement.scrollLeft + document.documentElement.clientWidth - offsetWidth);}";
}
else
{
cot_t1_DOCtp="_top:expression(document.body.scrollTop+document.body.clientHeight-this.clientHeight);_left:expression(document.body.scrollLeft + document.body.clientWidth - offsetWidth);}";
}

if(typeof document.compatMode!='undefined'&&document.compatMode!='BackCompat')
{
cot_t1_DOCtp2="_top:expression(document.documentElement.scrollTop-20+document.documentElement.clientHeight-this.clientHeight);}";
}
else
{
cot_t1_DOCtp2="_top:expression(document.body.scrollTop-20+document.body.clientHeight-this.clientHeight);}";
}


var botCSS='#topU{position:fixed;';
botCSS=botCSS+'_position:absolute;';
botCSS=botCSS+'bottom:0px;';
botCSS=botCSS+'right:0px;';
botCSS=botCSS+'clip: inherit;';
botCSS=botCSS+cot_t1_DOCtp;

var cot_tl_popCSS='#cot_tl_pop {background-color: transparent;';
cot_tl_popCSS=cot_tl_popCSS+'position:fixed;';
cot_tl_popCSS=cot_tl_popCSS+'_position:absolute;';
cot_tl_popCSS=cot_tl_popCSS+'height:194px;';
cot_tl_popCSS=cot_tl_popCSS+'width: 244px;';
cot_tl_popCSS=cot_tl_popCSS+'border: thin solid #000000;';
cot_tl_popCSS=cot_tl_popCSS+'right: 100px;';
cot_tl_popCSS=cot_tl_popCSS+'top: 30px;';
cot_tl_popCSS=cot_tl_popCSS+'overflow: hidden;';
cot_tl_popCSS=cot_tl_popCSS+'visibility: hidden;';
cot_tl_popCSS=cot_tl_popCSS+'z-index: 100;';
cot_tl_popCSS=cot_tl_popCSS+cot_t1_DOCtp2;

document.write('<style type="text/css">'+botCSS+cot_tl_popCSS+'</style>');

function cot_tl_bigPopup(url)
{
newwindow=window.open(url,'name');

if(window.focus)
{
newwindow.focus()
}
return false;
}

function cot(cot_tl_theLogo,cot_tl_LogoType,LogoPosition,theAffiliate)
{
var cot_tl_bigBaseURL= "http://fsforfun.blogspot.com";
document.write('<div id="topU">');
document.write('<a href='+cot_tl_bigBaseURL+' onClick="return cot_tl_bigPopup(\''+cot_tl_bigBaseURL+'\')"><img src='+cot_tl_theLogo+' border="0" ></a>');document.write('</div>');
}


Simpan code di atas dengan extensi *js pada hostingan anda, kemudian load menggunakan javascript linker