需要在圖片所在站點設置Access-Control-Allow-Origin,以下為設置方法:
Apache
Header set Access-Control-Allow-Origin 'https://m.destoon.com'
Nginx
add_header 'Access-Control-Allow-Origin' 'https://m.destoon.com';
IIS
設置HTTP 響應頭,如下圖:
或者在web.config里添加以下代碼:
<system.webServer> <httpProtocol> <customHeaders> <add name="Access-Control-Allow-Origin" value="https://m.destoon.com" /> </customHeaders> </httpProtocol> </system.webServer>
https://m.destoon.com 需要替換成手機版的實際域名