How to setup notifications

The notification code I had working before doesn’t seem to work on more recent iphones/ios versions.

 push = PushNotification.init({
                "ios": {
                }, 
            });
            push.on('registration', function(data) {
                REGISTRATIONOBJECT = data;
                llog('regobject '+JSON.stringify(REGISTRATIONOBJECT));
            });
<plugin name="cordova-plugin-device" spec="^1.1.7" />
<plugin name="cordova-plugin-dialogs" spec="^1.3.4" />
<plugin name="cordova-plugin-globalization" spec="^1.11.0" />
<plugin name="cordova-plugin-inappbrowser" spec="^1.7.2" />
<plugin name="cordova-plugin-splashscreen" spec="^3.2.2" />
<plugin name="cordova-plugin-statusbar" spec="^2.4.2" />
<plugin name="cordova-plugin-whitelist" spec="^1.3.3" />
<plugin name="cordova-plugin-file" spec="^4.3.3" />
<plugin name="phonegap-plugin-push" spec="1.5.3">
    <variable name="ANDROID_SUPPORT_V13_VERSION" value="27.+" />
    <variable name="FCM_VERSION" value="11.6.2" />
</plugin>
<engine name="ios" spec="^5.1.1" />

This is very unlikely to be a VoltBuilder issue. More likely, it has something to do with updated libraries or plugins.

I notice you’re using a very old version of the iOS library, one which won’t approved by Apple.

What’s a better iOS library to use?

It compiles and gets to the app store, just notifications don’t work.

If you leave out this line:

<engine name="ios" spec="^5.1.1" />

The latest library will be used.

If it builds the executable properly, the issue has to do with how you are using notifications. That’s out of scope for VoltBuilder Support, but perhaps others will gave suggestions here.

I tried a bunch of different iterations of versions for phonegap-plugin-push and the iphone engine, it seems like this breaks my login code. Is there a recent example of notification code I can try?

Hi Oliver … I has succes with Onesignal in both iOS and Android

My setup

Onesignal didn’t work, and added ads to my app. Is there a way to just get the push token?

Tried a few different plugins for notifications, but no luck. Ideally I’d use something I can dropin to replace phonegap-plugin-push.

Thank you for posting your question about a plugin. With around 1000, none of which are ours, VoltBuilder Support help much with plugins. We’re happy to help with VoltBuilder itself. We encourage other users to drop by if they know the answer. StackOverflow and the author of the plugin can also be a good sources of information.

Was able to do this with onesignal, required a decent bit of code change though

Hi … can you please tell about this ? thanks

A coworker told me it did, I think he was wrong though.

The phonegap-plugin-push was forked to cordova-plugin-push. The plugin itself works fine however in its current state it will not build on voltbuilder (or at least I can’t figure out how) because the latest version of the android.support vs androidX libraries.