iOS Not Receiving Push Notifications -


i'm in development mode , have created certificates development, app id , certificate apns. have been downloaded , installed on keychain , .p12 has been installed in server.

all of devices on provisioning profile have app installed , none receiving notification.

all ports open , has been tested simple php app , works, not server.

what missing?

it's bit vague it's working 'a simple php app'. more information on difference between flow of events on server , 'php app', draw more reasonable conclusions.

apart that, if haven't already, check out this great tutorial ali hafizji raywenderlich (two parts). has detailed explanation of pretty need, have used myself couple of times(looks has been updated since though). installing .p12 on server, while i'm pretty sure he's converting .pem-file along private key.

also make sure server using correct tokens, device's token different in development in distribution.

you should put health-checks server-side (in .php or whatever using establish connection gateway.push.apple.com) make sure server sending anything. i.e if you're using mysql access tokens, put down if(!$connection){die(mysql_error());} or something. should done when establishing connection apple. php , stream_socket_client, put this:

$fp = stream_socket_client(     'ssl://gateway.push.apple.com:2195', $err,     $errstr, 60, stream_client_connect|stream_client_persistent, $ctx);//$ctx=stream context  if (!$fp)     exit("failed connect: $err $errstr" . php_eol); 

and actual pushing of notification, or @ least php-way i've been using, fwrite() returns boolean wether successful or not, can $result = fwrite($fp, $msg, strlen($msg));, , $result 0 if fails.

also make sure you're connected system intend use(sandbox or not). might way off here, think once tried send notifications device production-profile when connecting apple's sandbox-system, , didn't receive anything. said certificates 'development', double-check else too.

then again, i'm having .php-code on server, , i'm not sure meant 'simple php-app works, server doesn't'.


Comments

Popular posts from this blog

c# - Send Image in Json : 400 Bad request -

jquery - Fancybox - apply a function to several elements -

An easy way to program an Android keyboard layout app -