Skip to content

Instantly share code, notes, and snippets.

@ktopping
Created June 22, 2011 16:14
Show Gist options
  • Select an option

  • Save ktopping/1040457 to your computer and use it in GitHub Desktop.

Select an option

Save ktopping/1040457 to your computer and use it in GitHub Desktop.
function flushThis(id){
var msie = 'Microsoft Internet Explorer';
var tmp = 0;
var elementOnShow = document.getElementById(id);
if (navigator.appName == msie){
tmp = elementOnShow.parentNode.offsetTop + 'px';
}else{
tmp = elementOnShow.offsetTop;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment