cordova

Running Cordova via a shell script - permission problem

北战南征 提交于 2020-06-17 15:50:05
问题 I have a shell script (called test.sh) which is called from PHP. Within the script I simply have: #!/bin/bash echo $(whoami) cordova platform version ios If I call test.sh from within terminal it works fine and returns the cordova ios version. If I try to call test.sh from with PHP I get: cordova: not found I have altered apache to run under my username instead of _www but that hasnt worked. Can anyone point me in the right direction as I'm guessing it is a permissions issue? I have now

Ionic app crash after adding use permission to config.xml file

纵然是瞬间 提交于 2020-06-17 09:13:25
问题 By adding MODIFY_AUDIO_SETTINGS permission to config.xml, my app will crash after run. <edit-config file="AndroidManifest.xml" mode="merge" target="/manifest/uses-permission" xmlns:android="http://schemas.android.com/apk/res/android"> <uses-permission android:name="android.permission.MODIFY_AUDIO_SETTINGS"/> </edit-config> Then run app: ionic cordova run android -- device Also i try for ionic android permission import { AndroidPermissions } from '@ionic-native/android-permissions/ngx'; this

Ionic app crash after adding use permission to config.xml file

我与影子孤独终老i 提交于 2020-06-17 09:12:47
问题 By adding MODIFY_AUDIO_SETTINGS permission to config.xml, my app will crash after run. <edit-config file="AndroidManifest.xml" mode="merge" target="/manifest/uses-permission" xmlns:android="http://schemas.android.com/apk/res/android"> <uses-permission android:name="android.permission.MODIFY_AUDIO_SETTINGS"/> </edit-config> Then run app: ionic cordova run android -- device Also i try for ionic android permission import { AndroidPermissions } from '@ionic-native/android-permissions/ngx'; this

Cordova build error “Requirements check failed for JDK 8 ('1.8.*')! Detected version: 11.0.2”

偶尔善良 提交于 2020-06-16 07:43:13
问题 when I try to compile with ionic my application tells me the following error: Checking Java JDK and Android SDK versions ANDROID_SDK_ROOT=undefined (recommended setting) ANDROID_HOME=/home/jmarroni/Android/Sdk (DEPRECATED) Requirements check failed for JDK 8 ('1.8.*')! Detected version: 11.0.2 Check your ANDROID_SDK_ROOT / JAVA_HOME / PATH environment variables. [ERROR] An error occurred while running subprocess cordova. Try installing the previous version of java 1.8 but do not recognize the

cordova: media.getDuration returns -1

放肆的年华 提交于 2020-06-16 04:24:11
问题 I am using Media.getDuration() function to get duration of an audio file but I am always getting -1 as response. This works fine if I build using build.phonegap.com But whenever I build using cli I then getDuration does not work. Following are simple steps to reproduce this issue: CLI: cordova start my_project cordova plugin add cordova-plugin-media cordova platform add android cordova build android www/index.html <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4

“Uncaught SyntaxError: Unexpected identifier”

痞子三分冷 提交于 2020-06-13 19:48:18
问题 I know this question asked many times but I tried to find solution but didn't get from available SO questions. I am very newbie on Javascript. I am trying to create sample calculation application in android using cordova. For that, I created cordova plugin. But I am getting two issues continuously. "Uncaught SyntaxError: Unexpected identifier", source: file:///android_asset/www/js/index.js (36) here is index.java code and error targetting performCalculation() first line. var app = { //

Show Decimal Keyboard in HTML5 iOS 7 / iOS 8

旧巷老猫 提交于 2020-06-11 16:42:06
问题 I just have a simple question after having searched for hours now: Is there any possibility to show the decimal keyboard in webbrowsers input fields? input type="number" only shows numbers but i need a comma or dot instead in the bottom left corner. I tried anything, pattern , step etc., but nothing brings up the decimal keyboard. I only need the numbers and a dot or comma, no A-Z or a-z or anything else. <input type="number" id="inputNumbers" pattern="[0-9]*" size="30" min="1" max="5"> This

Unable to set the sslVerify to false

只愿长相守 提交于 2020-06-09 08:46:09
问题 Actually I'm trying to install an ngCordova plugin for SQLite. But its giving me the error: Unknown SSL protocol error in connection to github.com:443 while accessing https://github.com/brodysoft/Cordova-SQLitePlugin.git/info/refs fatal: HTTP request failed. On doing some research, I came across the solution to set the sslVerify to false. I am not able to set the command git config http.sslVerify "false" using the command prompt. It is giving me the error: could not lock config file /

How to use this cordova plugin

情到浓时终转凉″ 提交于 2020-06-09 07:05:30
问题 I am building a video sharing app with ionic. I want when users wants to upload videos and it will give them a preview where they can trim the video, now I found the Cordova plugin that can do it, but I don't knowhow to use it Here is the plugin cordova-plugin-video-trim from https://www.npmjs.com/package/cordova-plugin-video-trim Now please, how can I use this plugin in my ionic application 回答1: Go to the project root and run these commands: cordova plugin add cordova-plugin-video-trim then

How to use this cordova plugin

一曲冷凌霜 提交于 2020-06-09 07:04:33
问题 I am building a video sharing app with ionic. I want when users wants to upload videos and it will give them a preview where they can trim the video, now I found the Cordova plugin that can do it, but I don't knowhow to use it Here is the plugin cordova-plugin-video-trim from https://www.npmjs.com/package/cordova-plugin-video-trim Now please, how can I use this plugin in my ionic application 回答1: Go to the project root and run these commands: cordova plugin add cordova-plugin-video-trim then