如何清除iframe的缓存?

时间:2020-01-03 05:59:02

标签: java php

我在iframe中询问一个平台和另一个平台。但是问题是我从父窗口注销,然后iframe抽出了钱。

<iframe scrolling="no" 
        id="chat_container" 
        src="<?php echo $this->meetingUrl; ?>" 
        allow="camera; microphone">
</iframe>

1 个答案:

答案 0 :(得分:1)

解决方案1:

您可以在iframe网址中添加随机字符串结尾。

<iframe scrolling="no" 
    id="chat_container" 
    src="<?php echo $this->meetingUrl; ?>?v=xkjsdkjhasdk" 
    allow="camera; microphone">
</iframe>

解决方案2:

请尝试在页面顶部添加html meta标签。

<meta http-equiv="cache-control" content="max-age=0" />
<meta http-equiv="cache-control" content="no-cache" />
<meta http-equiv="expires" content="0" />
<meta http-equiv="expires" content="Tue, 01 Jan 1980 1:00:00 GMT" />
<meta http-equiv="pragma" content="no-cache" />
相关问题