NokitaKaze

getElements, блеать

Jun 26th, 2014
75
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. function ge()
  2. {
  3.   var ea;
  4.   for( var i = 0; i < arguments.length; i++ ) {
  5.     var e = arguments[i];
  6.     if( typeof e == 'string' )
  7.       e = document.getElementById(e);
  8.     if( arguments.length == 1 )
  9.       return e;
  10.     if( !ea )
  11.       ea = new Array();
  12.     ea[ea.length] = e;
  13.   }
  14.   return ea;
  15. }
RAW Paste Data