{"id":26318,"date":"2024-05-21T11:56:53","date_gmt":"2024-05-21T03:56:53","guid":{"rendered":"https:\/\/www.zhidianwl.net\/zhidianwl\/?p=26318"},"modified":"2024-05-21T11:56:53","modified_gmt":"2024-05-21T03:56:53","slug":"ios%e6%8f%8f%e8%bf%b0%e6%96%87%e4%bb%b6%e6%89%93%e5%8c%85webapp%e6%80%8e%e4%b9%88%e5%81%9a%ef%bc%9f","status":"publish","type":"post","link":"https:\/\/www.zhidianwl.net\/zhidianwl\/2024\/05\/21\/ios%e6%8f%8f%e8%bf%b0%e6%96%87%e4%bb%b6%e6%89%93%e5%8c%85webapp%e6%80%8e%e4%b9%88%e5%81%9a%ef%bc%9f\/","title":{"rendered":"ios\u63cf\u8ff0\u6587\u4ef6\u6253\u5305webapp\u600e\u4e48\u505a\uff1f"},"content":{"rendered":"
iOS\u63cf\u8ff0\u6587\u4ef6\u662f\u4e00\u79cd\u7528\u4e8e\u5b89\u88c5\u548c\u914d\u7f6eiOS\u5e94\u7528\u7a0b\u5e8f\u7684\u6587\u4ef6\uff0c\u5176\u4e2d\u5305\u542b\u4e86\u5e94\u7528\u7a0b\u5e8f\u7684\u8bc1\u4e66\u3001\u6743\u9650\u3001\u6807\u8bc6\u3001\u8bbe\u5907\u5217\u8868\u7b49\u4fe1\u606f\u3002\u5728iOS\u5f00\u53d1\u4e2d\uff0c\u6211\u4eec\u901a\u5e38\u9700\u8981\u5c06\u5e94\u7528\u7a0b\u5e8f\u6253\u5305\u6210ipa\u6587\u4ef6\uff0c\u7136\u540e\u901a\u8fc7\u63cf\u8ff0\u6587\u4ef6\u8fdb\u884c\u7b7e\u540d\u548c\u5b89\u88c5\u3002\u672c\u6587\u5c06\u4ecb\u7ecd\u5982\u4f55\u4f7f\u7528iOS\u63cf\u8ff0\u6587\u4ef6\u6253\u5305WebApp\u3002<\/p>\n
\u9996\u5148\uff0c\u6211\u4eec\u9700\u8981\u4e86\u89e3WebApp\u7684\u6982\u5ff5\u3002WebApp\u662f\u4e00\u79cd\u4f7f\u7528Web\u6280\u672f\u5f00\u53d1\u7684\u5e94\u7528\u7a0b\u5e8f\uff0c\u5b83\u53ef\u4ee5\u8fd0\u884c\u5728\u79fb\u52a8\u8bbe\u5907\u7684\u6d4f\u89c8\u5668\u4e2d\uff0c\u5177\u6709\u7c7b\u4f3c\u539f\u751f\u5e94\u7528\u7a0b\u5e8f\u7684\u7528\u6237\u4f53\u9a8c\u3002WebApp\u901a\u5e38\u5305\u542bHTML\u3001CSS\u3001JavaScript\u7b49\u6587\u4ef6\uff0c\u53ef\u4ee5\u901a\u8fc7\u6d4f\u89c8\u5668\u6216\u8005\u684c\u9762\u5feb\u6377\u65b9\u5f0f\u542f\u52a8\u3002<\/p>\n
\u5728iOS\u4e2d\uff0c\u6211\u4eec\u53ef\u4ee5\u901a\u8fc7Safari\u6d4f\u89c8\u5668\u5c06WebApp\u6dfb\u52a0\u5230\u4e3b\u5c4f\u5e55\uff0c\u5e76\u4e14\u901a\u8fc7\u63cf\u8ff0\u6587\u4ef6\u8fdb\u884c\u7b7e\u540d\u548c\u5b89\u88c5\u3002\u4e0b\u9762\u662f\u5177\u4f53\u7684\u6b65\u9aa4\uff1a<\/p>\n
1. \u521b\u5efa\u4e00\u4e2aWebApp\uff0c\u5305\u542bHTML\u3001CSS\u3001JavaScript\u7b49\u6587\u4ef6\u3002<\/p>\n
2. \u5728WebApp\u7684\u6839\u76ee\u5f55\u4e0b\u521b\u5efa\u4e00\u4e2a\u540d\u4e3amanifest.plist\u7684\u6587\u4ef6\uff0c\u7528\u4e8e\u63cf\u8ff0WebApp\u7684\u4fe1\u606f\u3002\u8be5\u6587\u4ef6\u5305\u542b\u4ee5\u4e0b\u5185\u5bb9\uff1a<\/p>\n
“`<\/p>\n
CFBundleDisplayName<\/p>\n
WebApp\u540d\u79f0<\/p>\n
CFBundleIdentifier<\/p>\n
com.example.webapp<\/p>\n
CFBundleShortVersionString<\/p>\n
1.0<\/p>\n
CFBundleVersion<\/p>\n
1<\/p>\n
StartURL<\/p>\n
http:\/\/www.example.com\/index.html<\/p>\n
“`<\/p>\n
\u5176\u4e2d\uff0cCFBundleDisplayName\u8868\u793aWebApp\u7684\u540d\u79f0\uff0cCFBundleIdentifier\u8868\u793aWebApp\u7684\u552f\u4e00\u6807\u8bc6\uff0cCFBundleShortVersionString\u548cCFBundleVersion\u8868\u793aWebApp\u7684\u7248\u672c\u53f7\uff0cStartURL\u8868\u793aWebApp\u7684\u542f\u52a8\u9875\u9762\u3002<\/p>\n
3. \u5728WebApp\u7684\u6839\u76ee\u5f55\u4e0b\u521b\u5efa\u4e00\u4e2a\u540d\u4e3aicons\u7684\u6587\u4ef6\u5939\uff0c\u7528\u4e8e\u5b58\u653eWebApp\u7684\u56fe\u6807\u3002\u8be5\u6587\u4ef6\u5939\u5305\u542b\u4ee5\u4e0b\u6587\u4ef6\uff1a<\/p>\n
– icon-57.png: 57×57\u50cf\u7d20\u7684\u56fe\u6807<\/p>\n
– icon-72.png: 72×72\u50cf\u7d20\u7684\u56fe\u6807<\/p>\n
– icon-114.png: 114×114\u50cf\u7d20\u7684\u56fe\u6807<\/p>\n