Create Element And Set Attributes Javascript Array Functions