var _e ;(function(){ // Global closure START if(_e){ return } // Helpers // Create 'input' reliably with correct call or broken IE<8 call. // Pre-8 IE: // 1) Doesn't allow to set name on dynamicaly created element. // 2) Doesn't allow to set type after element is appended to tree. function input(type, name){ var ielem try{ // Old IE way var namea=''; if(name || name==0){ namea=' name="'+name+'"' } var typea=''; if(type){ typea=' type="'+type+'"' } ielem=document.createElement('') } catch(err){ ielem=document.createElement('input') } // Correct way ielem.name=name; ielem.type=type // Correct way + double it just in case IE way works for some weird reason return _e(ielem) } function input_return(where, type, name, value, prop, return_new){ var ielem=input(type, name) if(prop && (value || value==0)){ ielem.sp(prop, value) } if(where){ where.AppendChild(ielem) } // IE doesn't allows to change input type after append. if(return_new){ if(typeof(return_new)=='object'){ ielem.sp(return_new) } else { return ielem } } return where } // Copies properties from arguments to target object. Arguments can be any of // complete objects - every property will be copied from it or pair // of key+value strings. You can also mix them. function set_properties(target, args, method){ var len=args.length for(var idx=0; idx