apple-push-notifications

apple push notification with php script

三世轮回 提交于 2019-12-08 13:03:37
I am able to connected to the apns and by inserting the values to database for just check i am getting "message delivered" message but it's not showing any notification....can anybody tell me where i am mistaken... $deviceToken = '**********************'; $payload['aps'] = array('alert' => 'This is the alert text', 'badge' => 1, 'sound' => 'default'); $payload = json_encode($payload); $passphrase = '***'; $apnsHost = 'gateway.sandbox.push.apple.com'; $apnsPort = 2195; $apnsCert = 'ck.pem'; $streamContext = stream_context_create(); stream_context_set_option($streamContext, 'ssl', 'local_cert',

Cocos2d FCM Push Notification not working

风格不统一 提交于 2019-12-08 11:40:32
问题 I am creating a game in which I want to integrate Push notification. For ease of use I connected to FCM, trusting Google's service. I integrated FCM properly, as I think so, but still don't know what's missing but when I send any notification from Firebase Console, notification is not being received on my device. From starting only 1 time, I was able to receive the notification, that also lost with my ignorance but after that I am not able to receive notification event with same code and

Push Notifications: Associating a device token with a device

让人想犯罪 __ 提交于 2019-12-08 11:37:10
问题 My app is currently receiving push notifications that are associated with the previous application user account when this type of situation occurs: Player installs app and registers as "bob" bob's device token registered with web service Player reinstalled app and registers as "phil" (on same device) phil's device token registered with web service Even though the player is now logged in as "phil" they will continue to receive push notifications for the account associated with "bob" as well as

iOS8.1.2 didReceiveRemoteNotification method not called when device is not plugged in

笑着哭i 提交于 2019-12-08 11:00:26
问题 In iOS version is 8.1.2,I found a really strange issue: I implement below method to handle push info in appDelegate - (void)application:(UIApplication *)application didReceiveRemoteNotification:(NSDictionary *)userInfo fetchCompletionHandler:(void (^)(UIBackgroundFetchResult))completionHandler If your device is not plugged in,this method is not called. 回答1: If you look around, you'll see that others thought it would be a bug in iOS 7.1 beta, fixed in 7.1 release version, but it has probably

APNS-Development push SSL or Production push SSL?

半世苍凉 提交于 2019-12-08 10:47:34
问题 I want to create an application with apple push notification services. I have used Development Push SSL at the development time and I have done the app and all the testing, and its working fine. So now I want to distribute the app through appstore. So which one should i use? Development push SSL or Production push SSL? Thanks 回答1: You definitely need to setup and use the Production Certificates for app store releases. See the iOS Provisioning Portal, App ID's, then configure your certificates

Troubleshooting post-boot push notification delivery failures

只谈情不闲聊 提交于 2019-12-08 10:37:26
问题 My app receives push notifications successfully if run at least once per boot both in the background and when force closed (thanks to PushKit). If I reboot the device, I won't receive any pushes until I launch the app at least once. How can I get this scenario working? I'm running latest Xcode and iOS (8.3) If I leave the app running in the background when I reboot the device, the app still shows up in the recents menu however no pushes are received and no AppDelegate entry points are hit

How to push a new view upon opening push notification while app is closed?

↘锁芯ラ 提交于 2019-12-08 10:28:30
问题 So what I'm trying to do is when you click view on receiving a push notification when the app opens it has the presented view push a new controller with details regarding the notification. I'm using a UITabBarController with UINavigationControllers. Any help would be much appreciated, I've tried searching but I couldn't seem to find anything that pointed me in the right direction. Current code below: - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary

IOS notification content extension: add buttons in storyboard and handle the click action

和自甴很熟 提交于 2019-12-08 09:50:35
问题 IOS notification content extension: add buttons in MainInterface.storyboard and handle the click action without dismissing the notification 回答1: after making some research I discover that: can not handle buttons clicks in the IOS notification content extension, only the type of button can be used is the media button, see the IOS documentation: https://developer.apple.com/documentation/usernotificationsui/unnotificationcontentextension 回答2: The up answer is not correct, you can just add

Multiple FCM Senders: Programmatically load Sender ID and Server Key on Mobile App

萝らか妹 提交于 2019-12-08 09:48:21
问题 As part of our solution, we deploy an FCM "app server" at each of our customer sites. Each customer site need to generate their own sender id and server id for use with our app. The default FCM implementation places the Sender ID and Server Key in a plist (iOS) / json (Android) which is integrated into the app code at compile-time. However since we have multiple current customers and will have new customers, our mobile app needs to be able to make a service call to the customer App Server,

Pushing notifications using ApnsPHP is slow

偶尔善良 提交于 2019-12-08 09:40:00
问题 I'm using the ApnsPHP lib for my project to send push notifications to my users: private static function fnSendToIos($tokens, $text, $config) { set_time_limit(200); // Adjust to your timezone date_default_timezone_set('Europe/Moscow'); // Using Autoload all classes are loaded on-demand require_once 'ApnsPHP/Autoload.php'; // Instantiate a new ApnsPHP_Push object $push = new ApnsPHP_Push( ApnsPHP_Abstract::ENVIRONMENT_SANDBOX, $config['sert'] ); // Set the Root Certificate Autority to verify