cordova

API calls made in Ionic 4 app not working on Android device

此生再无相见时 提交于 2020-01-11 11:38:16
问题 I am able to run my ionic app on my laptop by using the ionic lab command. The app makes calls to the IMDB api, & displays data retrieved from it. Now, I am trying to run the app on an android device. by using the following command: ionic cordova run android --device . The app appears on my phone, but when I search for IMDB data, no results are appearing. Below is the service I am using to make calls to the API: export class MovieService { url = 'http://www.omdbapi.com/'; apiKey = 'myKey';

Where are files saved in PhoneGap app stored on Android?

时光怂恿深爱的人放手 提交于 2020-01-11 10:19:12
问题 I am using PhoneGap with File plugin. I am able to read & write files to file system and those are persisted correctly. But when I try to locate those files from native file explorer app on tablet or from Windows Explorer (through USB connection), I can't find any traces of these files by browsing to folder that PhoneGap claims to store those (Tablet\Android\data\com.xxx.yyy\files) to nor with search functionality. I do not have any external cards attached to my Android tablet. Any ideas how

cordova.file.* (all directories) are null

做~自己de王妃 提交于 2020-01-11 09:42:42
问题 I'm working on Ionic mobile app development. My requirement is to create client side logger to track issues in app. I used the methods mentioned in https://github.com/pbakondy/filelogger, and I could able to create the log file in both Android and iOS. For the first time when I open the app, it creates the log file in cordova.file.dataDirectory, when I close and reopen the app in i*OS , I'm trying to read the content of the file which was created using the below $fileLogger.getLogfile().then

Phonegap TouchEvent

六眼飞鱼酱① 提交于 2020-01-11 09:36:08
问题 My problem is that I want to play an audio/video file from the frontpage (index.html) It's working like that: function setaudio() { $("#aud").prepend('<a href=# onclick=playaudio();><img src=icons/audio_file.png alt=Audiodatei width=90px height=90px></a>'); } The function playing the audio: function playaudio() { window.plugins.videoPlayer.play(myaudio[0]);} The problem it's not working on the index.html but it's working on linked sites f.e audio.html where I am calling setaudio(); again...

How get data from cordova-plugin-nativestorage in android java

杀马特。学长 韩版系。学妹 提交于 2020-01-11 08:52:07
问题 Good day, I making native background mod for Cordova and I need get data from js to java. I save data in js with plugin cordova-plugin-nativestorage, with this code: <!DOCTYPE html> <html> <head> <title>Save data</title> <script type="text/javascript" charset="utf-8" src="cordova.js"></script> <script type="text/javascript" charset="utf-8"> function onLoad() { document.addEventListener("deviceready", onDeviceReady, false); } function onDeviceReady() { NativeStorage.setItem("somekey", "value",

Access localStorage or web database created in PhoneGap from Android native code

强颜欢笑 提交于 2020-01-11 08:50:32
问题 How is it possible to access Web SQL database created in PhoneGap app from native code in Android? I have a local notification plugin set up and what I want to achieve is fetch user setting from web database to set a correct interval for my alarm. 回答1: I have modified the Cordova(https://github.com/Coder-Nasir/incubator-cordova-android) in such a way that it will create the database in Android's Default location which is /data/data/package-name/databases/ By just this simple command window

jQuery / HTML5 / gwt app for WP8 (Lumia 920) device: vertical css scroll fix

二次信任 提交于 2020-01-11 07:41:29
问题 Problem: I try to fix this phenomenom about scrolling out of app boundaries: (Picture source: Prevent scrolling out of CordovaView in Cordova for Windows Phone 8 ) Approach #1 body { overflow: hidden; -ms-content-zooming: none; } this css snippet should fix scroll so that application is stabile when scrolling the content, which it does perfectly, but it leaves application unstable. Application hands now and then without any visible reason. Showing three different views in row freezes app.

PhoneGap add Facebook Connect plugin

雨燕双飞 提交于 2020-01-11 07:01:32
问题 I want to add com.phonegap.plugins.facebookconnect to my PhoneGap build android app but I unable to do it. In doc site they say to add <gap:plugin name="com.phonegap.plugins.facebookconnect"> <param name="APP_ID" value="..." /> <param name="APP_NAME" value="..." /> </gap:plugin> in config.xml file but there is 3 config.xml files in PhoneGap build folder and even when I add it what than? There should be files added to project like cdv-plugin-fb-connect.js and facebook-js-sdk.js so I can

Opening a PDF file in Windows Phone

旧街凉风 提交于 2020-01-11 06:34:56
问题 I'm developing an app for Windows Phone 7 and I'm using a Phonegap template for it. Everything looks perfect, but now I’m stuck trying to open a PDF file in the browser. I tried the following but that doesn’t work because the url of the PDF exceeds the 2048 character limit (it’s a data url). This code runs after the deviceReady event was fired. var ref = window.open('http://www.google.com', '_blank', 'location=no'); ref.addEventListener('loadstart', function () { alert(event.url); }); Now, I

Android Phonegap Compilations adds bar at the bottom of app that should not be there?

别说谁变了你拦得住时间么 提交于 2020-01-11 06:32:06
问题 I've looked everywhere and tried just about everything, but I can't get rid of this random black bar appearing at the bottom of my PhoneGap App. This is what I am seeing when I run the app: The interesting part is that if I minimize the app and then open it again, it automatically fixes the display and the bottom bar disappears. But why?! How can I get it to not show this bar from the moment the app opens? Also, this does not happen in Chrome on my desktop computer. It only happens after the