0
我正在構建使用jquery移動導航的phonegap應用程序。我有一個外部的PHP頁面查詢來自Db的項目並將它們加載到我的應用程序。所以我用外部php頁面未在APK中加載,但在紋波模擬器中工作
$(document).delegate("#cardslist", "pageinit", function() {
$.mobile.changePage("data/card-list.html", { transition: "fade", changeHash: false });
);
});
其中卡list.html是一個內部頁面,其內容爲
$(document).delegate(".cardslist", "pageinit", function() {
$.ajax({
method:'GET',
url:'http://www.thecardguys.co.ke/m/card-list-mobile.php',
beforeSend:function()
{
// $("#processing").show();
},
complete:function()
{
// $("#processing").hide();
},
success: function(feedback)
{
$('.cardlist').html(feedback);
$('.cardlist').css({'transform': 'scale(0.6)'});
}
});
}
http://www.thecardguys.co.ke/m/card-list-mobile.php是外部PHP頁面,獲取數據,並呼應它。
內容在紋波模擬器中載入良好,但是當我捆綁應用程序時數據將無法載入。已經過了一週的時間
嘿,謝謝你的回覆,我在網絡白名單上添加了網址。但它仍然顯示加載器,但不加載Feed。我試過https,這甚至不能加載模擬器。 – jonah
@jonah沒有更多的細節,我可以添加更多。既然你有一個APK,而不是自己構建它,那麼獲得任何調試信息將會很困難。如果您可以使用Cordova CLI自己構建它,則可以使用Safari或GapDebug(https://www.genuitec.com/products/gapdebug/)。如果您正在使用PhoneGapBuild,則它們提供調試工具來確定發生了什麼問題(http://docs.build.phonegap.com/en_US/debugging_remote_debugging_tools.md.html#Remote%20Debugging%20Tools)。 –
我沒有使用任何APK調試器。讓我試試genuitec.com/products/gapdebug – jonah