var logowidth=88
var logoheight=30
var logoimage=new Image(logowidth,logoheight)
logoimage.src="./madeonamic.png"
var alttext="made on a MicŪ"
var visibleduration=600
var Hoffset=15 
var Voffset=15 
var ie=document.all&&navigator.userAgent.indexOf("Opera")==-1
var watermark_obj=ie? document.all.watermarklogo : document.getElementById? document.getElementById("watermarklogo") : document.watermarklogo

function insertimage(){
if (ie||document.getElementById)
watermark_obj.innerHTML='<div style="background:url(./madeonamic.png);width:88px;height:30px"><img src="./spacer.gif" height="30" width="88" alt="'+alttext+'"></div>'
else if (document.layers){
watermark_obj.document.write('<div style="background:url(./madeonamic.png);width:88px;height:30px"><img src="./spacer.gif" height="30" width="88" alt="'+alttext+'"></div>')
watermark_obj.document.close()
}
}
function positionit(){
var dsocleft=ie? document.body.scrollLeft : pageXOffset
var dsoctop=ie? document.body.scrollTop : pageYOffset
var window_width=ie? document.body.clientWidth : window.innerWidth-20
var window_height=ie? document.body.clientHeight : window.innerHeight

if (ie||document.getElementById){
watermark_obj.style.left=parseInt(dsocleft)+parseInt(window_width)-logowidth-Hoffset
watermark_obj.style.top=parseInt(dsoctop)+parseInt(window_height)-logoheight-Voffset
}
else if (document.layers){
watermark_obj.left=dsocleft+window_width-Hoffset-logowidth
watermark_obj.top=dsoctop+window_height-logoheight-Voffset
}
}

function hidewatermark(){
if (document.layers)
watermark_obj.visibility="hide"
else
watermark_obj.style.visibility="hidden"
clearInterval(watermarkinterval)
}

function beingwatermark(){
watermarkinterval=setInterval("positionit()",50)
insertimage()
if (visibleduration!=0)
setTimeout("hidewatermark()",visibleduration*100000)
}

if (ie||document.getElementById||document.layers)
window.onload=beingwatermark
