I implemented push notification in my app and it is working when i install build from xcode but not working when i install app via a link generated by diawi.com why this is
As @sadiqxs notice there are two types of certs, and in a comment you can find excelent simplePush code (http://d1xzuxjlafny7l.cloudfront.net/downloads/SimplePush.zip).
BUT one often forgotten thing!
Your deviceToken
changed (!!!) while you compile to production (ad-hoc) and deploy from Xcode. What i suggest you to do is:
NSLog
the token in method: -(void)application:didRegisterForRemoteNotificationsWithDeviceToken:
sample:
- (void)application:(UIApplication*)application didRegisterForRemoteNotificationsWithDeviceToken:(NSData*)deviceToken {
NSString *dt = [[deviceToken description] stringByTrimmingCharactersInSet:[NSCharacterSet characterSetWithCharactersInString:@"<>"]];
dt = [dt stringByReplacingOccurrencesOfString:@" " withString:@""];
NSLog(@"%@",dt");
}
6a) If yes, problem solved
6b) If no, and you receive the push for dev env for sure you have an issue with certificates and regenerate them
While you using SimplePush script remember to change url to production (gateway.push.apple.com) from sandbox one.