ionic-framework

ionic cordovaSQLite plugin error Cannot read property 'openDatabase' of undefined

跟風遠走 提交于 2020-01-24 08:36:25
问题 I have 1 issue in ngCordova plugin cordovaSQLite. Below code: var db = $cordovaSQLite.openDB({ name: "myDB.db" }); i'm using "ionic serve" for run project in browser. error: Uncaught TypeError: Cannot read property 'openDatabase' of undefinedng-cordova.js:5058 openDBapp.js:27 (anonymous function)ionic.bundle.js:37388 (anonymous function)ionic.bundle.js:2241 onPlatformReadyionic.bundle.js:2220 onWindowLoad [Main error] http://i.stack.imgur.com/Yctpl.png Could you please help me? 回答1: As stated

ionic run android: Build failed with an exception

巧了我就是萌 提交于 2020-01-24 07:27:32
问题 What went wrong: Execution failed for task ':CordovaLib:processDebugResources'. com.android.ide.common.process.ProcessException: org.gradle.process.internal.ExecException: Process 'command '/home/vishal/sw/android/build-tools/23.0.3/aapt'' finished with non-zero exit value 127 Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. BUILD FAILED Total time: 3 mins 14.449 secs Error: Error code 1 for command: /var/www/html/street

Ionic 4 keyboard covers input field

感情迁移 提交于 2020-01-24 04:23:07
问题 I have an Ionic 4 app that has a form with inputs in it. When the user clicks on the input, it opens the keyboard, but it hides the content, without scrolling. Is there any way around this? This is my code: <form #f="ngForm" (ngSubmit)="sendMail()"> <ion-item> <ion-label position="floating">name </ion-label> <ion-input [(ngModel)]="senderName"> </ion-input> </ion-item> <ion-item> <ion-label position="floating">mail </ion-label> <ion-input [(ngModel)]="senderMail"> </ion-input> </ion-item>

Ionic 3 Native : File : {code: 5, message: “ENCODING_ERR”}

你。 提交于 2020-01-24 04:15:30
问题 I'm using the checkFile function from File API plugin in Ionic 3 to check if a file exists locally. The Promise rejects with the following error : FileError {code: 5, message: "ENCODING_ERR"} From what I see on the Mozilla Docs of the File API, the problem is that "The URL is malformed." However, I don't see how is the URL malformed. Here is the relevant code showing how I'm calling the function plus the actual values of involved variables (The value of baseDirectory is set to file:///data

Transparent navigation bar in Ionic

跟風遠走 提交于 2020-01-24 01:33:18
问题 My Ionic application have a detail view with transparent header. Applying CSS class "bar-clear" to my element is doing the job just fine in desktop browsers and when running the app on Android (see result here). But when running on iOS 8 the header is white and opaque (see here). Any idea why? 回答1: I did some research and people it got it working by setting bar-light to the header bar and then making these changes: .bar.bar-light { background-color: rgba(255,255,255,.66) !important; /* or

Ionic3/Angular4: Two-way databinding stops working after click event on Google-Maps

这一生的挚爱 提交于 2020-01-24 01:12:12
问题 I am using Ionic 3 and I am using the Google Maps plugin for it. I have two pages, a list and a map. I display the same objects on both views and when you click a list entry or a marker (info window), the object's detail page will be opened where you can rate the selected object. Anyway, when I open the detail page via the list, everything works fine but when I open the detail page via the map-marker, the two-way data binding stops working. In the code below you can find the <rating-input>

How to get sim card contacts in ionic framework or cordova

|▌冷眼眸甩不掉的悲伤 提交于 2020-01-23 18:12:07
问题 I am trying to get All contact from Phone and Sim card in ionic frame work.I got all contact from Phone but not from SIM I tried Link for NGCORDOVA CONTACTS but from this not able to get SIM contacts I tried to get sim info by SIM INFO PLUGIN from this got all info but not sim contacts. what to do please help. 回答1: Using following plugin DeviceInformation plugin. It is used to get the following information from your device and sim. Your unique Device ID Phone Number (if it is stored in your

Ionic 4 - Customize context menu

放肆的年华 提交于 2020-01-23 11:12:47
问题 I'm building an Ionic app that has heavy text editing, and I would like to customize the context menu that appears when making a text selection (shown below). How can I add buttons to this menu? Can it be customized even further? Is it possible to switch this menu out entirely for some custom HTML menu else that appears when the user makes a text selection? I've seen the plugin cordova-plugin-context-menu but it does not seem to be what I need (although it's hard to say because it doesn't

Ionic 4 - Customize context menu

对着背影说爱祢 提交于 2020-01-23 11:12:24
问题 I'm building an Ionic app that has heavy text editing, and I would like to customize the context menu that appears when making a text selection (shown below). How can I add buttons to this menu? Can it be customized even further? Is it possible to switch this menu out entirely for some custom HTML menu else that appears when the user makes a text selection? I've seen the plugin cordova-plugin-context-menu but it does not seem to be what I need (although it's hard to say because it doesn't

Why is the error ERR_CLEARTEXT_NOT_PERMITTED with cleartext for the HTTP traffic persistent?

帅比萌擦擦* 提交于 2020-01-23 09:57:15
问题 I'm developing a new app using the Ionic-framework and I'm using the HttpClient module for API requests. The problem is that I've read and tried to apply the solutions on: https://medium.com/@son.rommer/fix-cleartext-traffic-error-in-android-9-pie-2f4e9e2235e6 https://forum.ionicframework.com/t/livereload-err-cleartext-not-permitted/163487 Android 8: Cleartext HTTP traffic not permitted Why am I seeing net::ERR_CLEARTEXT_NOT_PERMITTED errors after upgrading to Cordova Android 8? How to fix