解决页面照片名字相同时,照片存在缓存无法及时更换的问题

    技术2022-07-12  84

    双重保险:

    在页头加上:

    <meta http-equiv="pragma" content="no-cache"/> <meta http-equiv="cache-control" content="no-cache"/> <meta http-equiv="expires" content="0"/>

    在图片地址后加上随机数,表示每次加载图片地址不同

    <img src="图片地址?random="+Math.random(); />

     

    Processed: 0.012, SQL: 10