function DockToBottomRight() 
{ 
var windowHeight = document.body.clientHeight; 
var windowWidth = document.body.clientWidth; 
var windowScrollTop = document.body.scrollTop; 
var windowScrollLeft = document.body.scrollLeft; 

var boxPanel = document.getElementById("mybox"); 

if(navigator.userAgent.indexOf("Firefox") != -1)
{ 
   windowHeight = window.innerHeight - 70; 
   windowWidth = window.innerWidth;
   boxPanel.style.top = windowHeight + windowScrollTop;   
   boxPanel.style.left = windowWidth + windowScrollLeft - boxPanel.clientWidth; 
}
else
{
  boxPanel.style.top = windowHeight + windowScrollTop - boxPanel.clientHeight;   
  boxPanel.style.left = windowWidth + windowScrollLeft - boxPanel.clientWidth; 
}


} 

window.onscroll=DockToBottomRight; 
window.onresize=DockToBottomRight; 
window.onload=DockToBottomRight; 
