Now Offline

I added javascript functions to make it work offline