Opening links in external device browser with Cordova/jQuery-mobile

后端 未结 5 1534
故里飘歌
故里飘歌 2021-01-17 23:09

I have a bunch of links in my app. I added rel=\'external\' target=\'_blank\' to all of them.

In the Ripple emulator, or in a regular desktop browser,

5条回答
  •  轻奢々
    轻奢々 (楼主)
    2021-01-17 23:57

    I've searched ages for the correct answer and managed to fix this another way besides the already given answers.

    First of all, older versions of Cordova seem to break when you're using some methods on the newer versions of Android. Updating your Cordova to the latest version will bring some possible migration problems in your current project but is worth the shot of updating. Updated to Cordova 5.0 from 2.8, cost me around half an hour changing the code (just a few fixes required). Rebuilded, deployed and launched succesfully after. The back button made my app crash at the older versions of Cordova. The newer version made it work like a charm with the same line of code. Long story short, update cordova, change a few lines if required and rebuild your beauty.

    Hope this will help you from not struggeling days like I did.

提交回复
热议问题