I'm using this code to rate app from an ios application.
let appLink = "https://itunes.apple.com/us/app/[name of the app]/id[idnumber]?mt=8"
let url = URL(string: appLink)
UIApplication.shared.openURL(url!)
the problem is Safari says "the page address is invalid"
Is there any way to make it work? I'm using xcode 9 and swift 4
Your URL can simply be:
https://itunes.apple.com/app/id<App ID Here>?mt=8
Better yet, use SKStoreProductViewController
so you can show the app in an App Store page without the need to leave your app.
And as of iOS 10.3 you can SKStoreReviewController
specifically to allow a user to post a review or rate an app.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With