phonegap-pushplugin

Cordova PushPlugin: Android won't play push sound while app not running

大憨熊 提交于 2019-12-21 21:18:14
问题 I'm using the PushPlugin for cordova, and in android, I can't make the push notification play a sound while the app is not running or in background (the banner in status bar is presented ok). Here's the function that gets called on android push notifications- function onNotification(e) { . . . case 'message': { var myMedia = new Media("/android_asset/www/res/raw/tritone.mp3"); myMedia.play({ numberOfLoops: 2 }) the sound plays fine while app is running in foreground. This is the 'e' param

Phonegap Push Plugin not working in Nougat

风流意气都作罢 提交于 2019-12-14 03:32:58
问题 I am using the latest Phonegap Push Plugin for my Phonegap Application. It's working fine below Nougat but in Nougat the same code does not work. I have tried to debug several times, also cross verified at server side if there is anything missing but found the device is not recognized by the GCMSender. Also everytime I uninstall and reinstall the Application the registered device token is same whereas in case of the Pre Nougat devices, it's always different after each uninstall and fresh

FCM (Bug) - Send a notification to multiple topics without using the OR operator.

雨燕双飞 提交于 2019-12-13 03:18:59
问题 Apparently, After having an issue with the (OR ||) operator, As the notification was received when i used the (AND &&) operator and it wasnt when i used (OR ||). Google confirmed that the OR operator is not working currently in FCM condition field : So is there another way i could send a notification to those who are subscribed to ( TopicA or TopicB or TopicC ) without the (OR ||) operator? 回答1: Update - So ive contacted FCM support & they helped me with a workaround using the (AND &&) And

Cordova Pushplugin: ecb not called

南楼画角 提交于 2019-12-12 10:39:59
问题 I am trying to retrieve the device registration ID in order to send notifications to it from my backend. I already gave it several tries: Outside my Object GambifyApp.NotificationManager = window.GambifyApp.NotificationManager = Ember.Object.extend({ init: function(){ var pushNotification = window.plugins.pushNotification; window.GambifyApp.NotificationHandler = GambifyApp.NotificationHandler; if ( device.platform == 'android' || device.platform == 'Android' ) { console.log('pushNotification

How to access isolated storage file from HTML or Javascript for Windows Phone and PhoneGap Application

元气小坏坏 提交于 2019-12-12 02:56:01
问题 I am using PhoneGap to develop application for Windows, Android and iOS platform. I have one problem and need expert assistance from you guys. I have created one plugin for Windows Phone. Plugin is basically download images from URL and stored in isolated storage folder inside Downloads folder this is working successfully. Now my problem is does there any way to access isolated storage files from javascript. for example i have downloaded one image and stored in isolated storage ("Download

APN and GCM Push Notifications opening a url in cordova app

妖精的绣舞 提交于 2019-12-12 02:03:43
问题 Using Cordova PushPlugin and AngularJS I want to receive a push notification and read a URL in the payload and then navigate to that page when the notification is swiped open. How is this accomplished? I tried this, but this is inside of a global function that is outside of angular so I wouldn't suspect the $location to work. It doesn't throw any errors though, but it also does not navigate to the url from the payload. function onNotificationAPN(event) { $location.path(event.custom.url) });

PushNotification not working with the app in background

≯℡__Kan透↙ 提交于 2019-12-11 16:19:44
问题 I'm developing an iOS and android app using ionic/cordova , and I'm trying to get the push notifications working on both platforms with the PushPlugin library. The thing is I'm getting the push notifications working OK for iOS , but in android is a little weird what is going on, when the app is in foreground, the notification arrives successfully , but when the app is in background (the app is close), the notification never arrives... Any thoughts about this? Permissions ? I followed this

cordova phonegap - How to use android API level 21

半世苍凉 提交于 2019-12-11 14:48:31
问题 Hey I forked the push notification plugin (https://github.com/alexislg2/PushPlugin) and added it to my project. The project won't compile with cordova build because I have a error: cannot find symbol error. The reason is that I use in the plugin Notification.setCategory() method which is Android SDK 21. How to force cordova to compile using API level 21? I installed the android 21 sdk build tools + I set <preference name="android-targetSdkVersion" value="21" /> in my config.xml But cordova

How to handle push notification in firebase

假装没事ソ 提交于 2019-12-11 02:49:50
问题 I'm developing a real time chat application using firebase and phonegap,I need to handle push notifications when application is not running.Please guide me to handle push notification at my backend server for firebase changes. thanks 回答1: Firebase directly has nothing to do with push notifications. If your server is a node.js server, you can listen for changes in your Firebase instance and respond to those changes with push notifications. Read more : Where does Firebase fit in your app?

Phonegap push notification plugin with iOs

梦想的初衷 提交于 2019-12-10 12:06:07
问题 I'm using phonegap-plugin-push to send push notifications to Android devices. I'm trying to figure out how to send notification to iOs. I've registered at https://developers.google.com/mobile/add?platform=ios&cntapi=gcm&cnturl=https:%2F%2Fdevelopers.google.com%2Fcloud-messaging%2Fios%2Fclient&cntlbl=Continue%20Adding%20GCM%20Support&%3Fconfigured%3Dtrue I'get token at client app same way as in Android: var push = PushNotification.init({ android: { senderID: "5993...475" }, ios: { alert: "true