document.getElementsByClassName = function(class_name) {
  var all_obj,ret_obj=new Array(),j=0;
  if(document.all)all_obj=document.all;
  else if(document.getElementsByTagName && !document.all)all_obj=document.getElementsByTagName("*");
  for(i=0;i<all_obj.length;i++) {
    if(all_obj[i].className==class_name) {
      ret_obj[j]=all_obj[i];
      j++;
    }
  }
  return ret_obj;
}