我在头部有这个index.php
:
<link rel="apple-touch-startup-image" href="images/screenLD.png" media="(device-width:320px)" /><!--iPod/iPhone Portrait LD 320x460-->
<link rel="apple-touch-startup-image" href="images/screenHD.png" media="(device-width:320px)and(-webkit-device-pixel-ratio:2)" /><!--iPod/iPhone Portrait HD 640x920-->
<link rel="apple-touch-startup-image" href="images/screenPortraitLD.png" media="(device-width:768px)and(orientation:portrait)" /><!--iPad Portrait LD 768x1004-->
<link rel="apple-touch-startup-image" href="images/screenLandscapeLD.png" media="(device-width:768px)and(orientation:landscape)" /><!--iPad Landscape LD 748x1024-->
<link rel="apple-touch-startup-image" href="images/screenPortraitHD.png" media="(device-width:1536px)and(orientation:portrait)and(-webkit-device-pixel-ratio:2)" /><!--iPad Portrait HD 1536x2008-->
<link rel="apple-touch-startup-image" href="images/screenLandscapeHD.png" media="(device-width:1536px)and(orientation:landscape)and(-webkit-device-pixel-ratio:2)" /><!--iPad Landscape HD 1496x2048-->
这在cache.manifest
:
CACHE MANIFEST
index.php
images/screenLD.png
images/screenHD.png
images/screenPortraitLD.png
images/screenLandscapeLD.png
images/screenPortraitHD.png
images/screenLandscapeHD.png
但是我们很容易理解,一个 iPhone 用户需要缓存另外 5 张无用的大图。
我怎样才能让他只缓存他需要的图像?
顺便说一句,对于那些想要在每个苹果设备上运行的闪屏代码的人来说,我的是完美的。