问题
How do I launch my app only for iPhone/iPod, not for iPad on the App Store? I can't seem to find any setting neither in my .plist file nor in iTunesConnect. Thanks!
回答1:
Just check Build Settings
and find key: Targeted device family
There you have iPhone
, iPad
or iPhone/iPad
options to choose
When you build the app and send it to Apple, it just checks values there and makes it available for the device specified.
回答2:
You can't. Apple's App store guidelines appear to specifically not allow iPhone apps that don't run or that crash under (1X/2X) compatibility mode on an iPad.
回答3:
It's an old question but the answer could be useful to other developers:
- If you want your app to run on both iPhone and iPod I don't see the point to prevent it from running on an iPad under (1X/2X) compatibility mode. You may loose some consumers for nothing.
- If you want your app to run on iPhone only because you need some capabilities like telephony. The good way would be to use UIRequiredDeviceCapabilities and to set "sms" and "telephony". See Apple doc for more details: https://developer.apple.com/library/ios/qa/qa1397/_index.html
回答4:
One way I could see this working is like this:
-(BOOL) application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
if (UIDevice.currentDevice.userInterfaceIdiom == UIUserInterfaceIdiomPad)
return NO;
// rest of launching code
return YES;
}
来源:https://stackoverflow.com/questions/11056725/app-store-launching-for-iphone-ipod-only-not-ipad