adding phonegap js support