Move the offline/online event binding to ensure Phonegap compatibility.  Fixes #7.