Example from http://www.raywenderlich.com/30734/phonegap-tutorial-a-cross-platform-zombie-app