iOS-openUrl的用法总结
[[UIApplication sharedApplication] openURL:url];
通过给url不同的值,可以实现调用系统自带 电话/短信/邮箱/浏览器/...
1、调用 电话phone
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"tel://800888"]];
拨打电话时不出现确认框
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"telprompt://800888"]];
拨打电话之时弹出确认框
2、调用自带 浏览器safari
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"http://www.abt.com"]];
3、调用 自带Mail
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"mailto://admin@abt.com"]];
4、调用 SMS
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"sms://800888"]];
5、调用 app Store
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"itms-apps://"]];
6、调用 iBook
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"itms-books://"]];
7、调用 Map
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"maps://"]];
8、调用 Facetime
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"facetime://"]]; 注意后面加上faceTime的账号如:99999@qq.com
9、调用 Music
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"music://"]];
10、跳转到系统设置相关界面
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=WIFI"]];
以下为设置的跳转关键字
//打开关于本机
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=General&path=About"]];
//打开辅助功能
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=General&path=ACCESSIBILITY"]];
//设置飞行模式不成功,即设置界面
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=AIRPLANE_MODE"]];
//屏幕几分钟之后锁定设置
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=General&path=AUTOLOCK"]];
//打开Brightness不成功,设置界面
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=Brightness"]];
//打开蓝牙设置
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=Bluetooth"]];
//设置日期与时间设置
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=General&path=DATE_AND_TIME"]];
//打开FaceTime设置
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=FACETIME"]];
//下面是打开通用设置
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=General"]];
//打开键盘设置
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=General&path=Keyboard"]];
//打开iClound设置
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=CASTLE"]];
//打开iCloud下的储存空间
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=CASTLE&path=STORAGE_AND_BACKUP"]];
//打开通用下的语言和地区设置
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=General&path=INTERNATIONAL"]];
//打开隐私下的定位服务
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=LOCATION_SERVICES"]];
//打开设置下的音乐
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=MUSIC"]];
//打开音乐下的均衡器
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=MUSIC&path=EQ"]];
//打开音乐下的什么不成功
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=MUSIC&path=VolumeLimit"]];
//打开通用下的网络不成功
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=General&path=Network"]];
//打开通用下的什么不成功
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=NIKE_PLUS_IPOD"]];
//打开设置下的备忘录设置
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=NOTES"]];
//打开设置下的通知设置
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=NOTIFICATIONS_ID"]];
//打开电话设置
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=Phone"]];
//打开设置下照片和相机设置
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=Photos"]];
//打开通用下的描述文件
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=General&path=ManagedConfigurationList"]];
//打开通用下的还原设置
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=General&path=Reset"]];
//打开设置下的safari设置
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=Safari"]];
//打开siri不成功
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=General&path=Assistant"]];
//打开设置下的声音设置
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=Sounds"]];
//打开通用下的软件更新
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=General&path=SOFTWARE_UPDATE_LINK"]];
//打开通用下的iTounes Store和App Store设置
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=STORE"]];
//打开设置下的twitter设置
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=TWITTER"]];
//打开通用下的用量
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=General&path=USAGE"]];
//打开通用下的vpn设置
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=General&path=VPN"]];
//打开设置下的墙纸设置
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=Wallpaper"]];
//打开wifi设置
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=WIFI"]];
//打开不成功
//[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root= INTERNET_TETHERING"]];