简体   繁体   中英

Push notification not working register

This feature did not work in my code, I'm trying to get the token device on iOS but it still fails.

ionic.Platform.ready(function() {
     window.plugins.pushNotification.register(
     function(token){
       alert(token);
     },
     function(){
       alert('Error al registrarse en el servidor APNS');
     },
     {
       "badge":"true",
       "sound": "true",
       "alert": "true",
       "ecb": "onNotificationAPN"
     });
 });

Nor send me any errors, testing with gapDebug. Can anyone help me with this error?

Thanks

You should build/sign your app using addhoc. Install the signed app on real device [via testflight, for example]. Then see if you get your device registered. "It never will when running in debugger on your phone from xCode"

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM