简体   繁体   中英

Phonegap - app works on desktop, not on mobile

I have created a web app using HTML, CSS and JS. In previous stages of the app, I have successfully loaded it on to my phone using Phonegap Build, and it "worked" there (still had a ton of bugs).

Now, I have fixed all the bugs and made the app prettier, and it works perfectly on my computer (even in chrome's device simulation with my phone's model in there).
The thing is, when I use Phonegap Build just like I did before, in my phone, the app doesn't respond, and it doesn't work. That made me wonder:
Are there some limitations to what you can do with Phonegap? Or whatever works on the desktop should work too?

To see exactly what's going on, I added a #console element to the DOM, and logged there in every action. It seems that the $(document).ready() is working, but that's pretty much it. It doesn't respond to clicks, nor to form submits.

I cannot post the code here because it's way too long.

i have build a android app with your code.

Because I use cordova so I change your phonegap.js into cordova.js and it works well.

在此输入图像描述

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM