cleaned up code; got json data displaying functioning