ios描述文件自动下载配置

第一步:修改NGINX的mime.types文件;

在/etc/nginx/mime.types添加:
application/x-apple-aspen-config mobileconfig;

第二步:设置返回的Content-type;

response.set_header(‘Content-type’,’application/x-apple-aspen-config’)
response.set_header(‘Content-Disposition’,’attachment; filename=”kanpian_vpn_seting.mobileconfig”‘)

然后就可以强制下载这个文件,并且自动打开了。

转载随意~:陶醉seo » ios描述文件自动下载配置

赞 (335)
分享到:更多 ()