apple-push-notifications

Send Apple Push Notifications via PHP (curl)

五迷三道 提交于 2020-01-16 22:07:44
问题 Tell me how to send a message by means of a push on the CURL php? This commitment does not work: $ch = curl_init(); curl_setopt($ch, CURLOPT_URL,'https://gateway.push.apple.com:2195'); curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1); curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); curl_setopt($ch, CURLOPT_HEADER, 1); curl_setopt($ch, CURLOPT_HTTPHEADER, array("Content-Type: application/json")); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_SSLCERT,'1.pem'); curl_setopt($ch, CURLOPT

Send Apple Push Notifications via PHP (curl)

两盒软妹~` 提交于 2020-01-16 22:07:27
问题 Tell me how to send a message by means of a push on the CURL php? This commitment does not work: $ch = curl_init(); curl_setopt($ch, CURLOPT_URL,'https://gateway.push.apple.com:2195'); curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1); curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); curl_setopt($ch, CURLOPT_HEADER, 1); curl_setopt($ch, CURLOPT_HTTPHEADER, array("Content-Type: application/json")); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_SSLCERT,'1.pem'); curl_setopt($ch, CURLOPT

Silent notification callback method called only when app is in background

回眸只為那壹抹淺笑 提交于 2020-01-16 02:49:05
问题 I registered remote notification and its working absolutely fine. Now I am implementing silent notification . For that, I enabled background remote notification and App downloads content from the network. and sending, {"aps": {"content-available": 1}} its calling the below callback method but only when app is in background: - (void)application:(UIApplication *)application didReceiveRemoteNotification:(NSDictionary *)userInfo fetchCompletionHandler:(void (^)(UIBackgroundFetchResult result)

Server name of apple for push notification testing in Production

一曲冷凌霜 提交于 2020-01-16 01:10:55
问题 What is the apple server's/host name for push notification testing of iPhone in production mode? 回答1: For production: gateway.push.apple.com, port 2195 For development: gateway.sandbox.push.apple.com, port 2195 Note: Every app generates different pushtokens for production and development mode. Don't send the same one to both. Source: Apple 来源: https://stackoverflow.com/questions/19784043/server-name-of-apple-for-push-notification-testing-in-production

Apple Push Notification in Production Environment : Unable to get local issuer certificate

吃可爱长大的小学妹 提交于 2020-01-15 10:54:27
问题 I applied APNS push notification in my server using Push development certificate for my App. It works fine until I try to change the certificate to Push production certificate. I try to test the connection with : openssl s_client -connect gateway.push.apple.com:2195 -cert myCert.pem -key myKey.pem After I enter a correct password, a summary is displayed : New, TLSv1/SSLv3, Cipher is AES256-SHA Server public key is 2048 bit Secure Renegotiation IS supported Compression: NONE Expansion: NONE

NotificationServiceExtension not called

▼魔方 西西 提交于 2020-01-14 13:35:30
问题 After iOS 10 released, I use NotificationServiceExtension for image notification. It works fine. But I found something wrong recently. Codes in UNNotificationServiceExtension not call anymore. I'm not sure the cause so I create a new project for test. Unfortunately the new project not work neither. I found something strange: Run extension in my device, locked screen, then push notification. Xcode raises this message(Extension is called obviously), unlocked and Xcode print " Program ended with

APNS notification received but not display

若如初见. 提交于 2020-01-14 13:15:13
问题 I am trying to implement pushnotification. I get pushed message when app is running state. - (void)application:(UIApplication *)application didReceiveRemoteNotification:(NSDictionary *)userInfo { NSLog(@"\n\n\n apns==%@\n\n\n",userInfo); } my problem is when I pushed message when app is not running means badge count only show on the app icon. It will not display the alert like close and view buttons. Even I cont predict - (BOOL)application:(UIApplication *)application

Get all the notification when device connect back to the internet in ios

自古美人都是妖i 提交于 2020-01-14 06:49:09
问题 I have developed one iOS chat app in objective-c, in which when UserA send message to UserB at that time UserB get push notification. When UserB get push notification it is calling one url to my backend to know UserA that your message is delivered to UserB(when app is not running or killed). This all working fine visa-versa. But my problem is that when UserA sends more than 5-10 message to UserB and UserB is not connected to the internet(my backend is also sending successful message to UserB

What things needed to add APN in .NET server

≡放荡痞女 提交于 2020-01-14 06:35:48
问题 As i have serch on google i am not sure that what things needed to implement APN in .NET server. In PHP server we create .PEM file but my .NET developer ask me for .P12 file so i am confuse. As this nice Tutorial from raywenderlich suggest what thing need to generate for PHP server which is .PEM file but what for .NET? AS this tutorial suggest I have The CSR (of developer certificate) The private key as a p12 file (myapp.p12) (of development certificate) The SSL certificate, aps_development

Not able to send push notification to iOS devices through MFP Server V8 Console

眉间皱痕 提交于 2020-01-14 04:07:11
问题 I am trying to send a push notification to an iOS device through MobileFirstPlatform V8.0 Server Console but when I am sending the notification I am getting the following error: An error occurred while the notification was sent. Internal server error. No devices found. I checked in Home -> mfp -> Devices , the devices exist there: I am able to successfullly send a notification to the android devices. Its just the iOS ones which are causing the problem. UPDATE I enabled the trace and when I am