Is there any Has anyone seen this or have any suggestions?
Thank you
This does not work:
- (void)application:(UIApplication *) application didRegisterForRemoteNotificationsWithDeviceToken:(NSData *)_deviceToken
NSLog(@"=== Device token: %@", [[[NSString alloc] initWithData:_deviceToken encoding:NSUTF8StringEncoding] autorelease]);
Do this:
NSLog(@"data %@", _deviceToken);
I am I received the callback didRegisterForRemoteNotificationsWithDeviceToken:, but the data returned to me is empty…. So I don’t know the device token.
Has anyone seen this before or have any suggestions?
Thank you
The answer is that I can’t just use UTF8 encoding to read the NSData token into NSString and expect it to display the token. < p>
This does not work:
- (void)application:(UIApplication *)application didRegisterForRemoteNotificationsWithDeviceToken:(NSData *)_deviceToken
NSLog(@"=== Device token: %@", [[[NSString alloc] initWithData:_deviceToken encoding:NSUTF8StringEncoding] autorelease]);
Do this:
< p>
NSLog(@"data %@", _deviceToken);