Is it possible to show the push notification prompt again once it is shown?

Discussion in 'iOS Programming' started by MacMan988, Apr 15, 2014.

  1. MacMan988 macrumors 6502a

    Joined:
    Jul 7, 2012
    #1
    Hi, I need to test the push notifications handling logic in my app. It presented the alert asking the user to enable or disable push notification. But it is not coming up anymore even if I remove the app and re-install it. Any ideas on how to get it back?
     
  2. dejo Moderator

    dejo

    Staff Member

    Joined:
    Sep 2, 2004
    Location:
    The Centennial State
    #2
    This isn't really an iOS Programming question, but just a general iOS question, to me. Let me know if you'd like me to move your thread to the appropriate forum.

    Did you pick the disable option?

    Go to the Settings app > Notification Center. Does your app appear in the Include or Do Not Include section? If so, which one?
     
  3. swiftaw macrumors 603

    swiftaw

    Joined:
    Jan 31, 2005
    Location:
    Omaha, NE, USA
    #3
    I believe if you uninstall the app and leave it uninstalled for at least 24 hours then reinstall it you will be prompted about push notifications again.
     
  4. waterskier2007 macrumors 68000

    waterskier2007

    Joined:
    Jun 19, 2007
    Location:
    White Lake, MI
    #4
    I think OP is asking as a developer, is it possible to manually prompt the user again, even if they declined push notifications the first time.

    I don't believe this is possible because the only time it is presented is when you first call

    Code:
    - (void)registerForRemoteNotificationTypes:(UIRemoteNotificationType)types
    
    Any subsequent call just checks that the device is still registered
     
  5. dejo Moderator

    dejo

    Staff Member

    Joined:
    Sep 2, 2004
    Location:
    The Centennial State
    #5
    Ah, I see. Apologies for the misunderstanding.
     
  6. alwaysonthego macrumors newbie

    Joined:
    Apr 17, 2014
    #6
    This worked for me!

    Re: is it possible to get the push notification prompt back after you have pressed "don't allow"

    I found a post on the web that told me to go to settings > notification center > go to the app that you need push notifications for, open it and make sure that all badge app icon, sounds and alerts are on for the app, then go back to settings and turn "airplane mode" off for 30 seconds then back on....I then had push notifications active again for that app. Happy Happy Happy!

    Hope this helps! It worked for me! :)
     
  7. dan-at-roost macrumors newbie

    Joined:
    Nov 16, 2013
    Location:
    Ohio
    #7
    Curious... It should reprompt after a uninstall / install. But no - it is not possible to reprompt a user in an iOS app for permissions. This applies to location, access to photos, push notifications, etc.

    This is the same for push notifications on Safari for desktop browsers. (Side note I know, but it seems related.)

    I cam across this post on TechCrunch not that long ago that really puts this into perspective, as far as pain-point for asking user permissions. Again, not totally related but seemed very on point.

    http://techcrunch.com/2014/04/04/the-right-way-to-ask-users-for-ios-permissions/
     

Share This Page