addded html5 webstorage as db, and db code