function createElement(a, b) { if(a.constructor == String) a = document.createElement(a); for(var x in b) { if(b[x].constructor == Object) { createElement(a[x], b[x]); continue; } a[x] = b[x]; } return a;}