Microsoft Teams 选项卡 X - 框架 - 选项
Microsoft Teams Tab X - Frame - Options
我已经为 Microsoft Teams 创建了一个选项卡。添加到频道后显示错误:
Refused to display 'URL' in a frame because it set 'X-Frame-Options' to 'sameorigin'.
该选项卡应该加载托管在 Azure 中的应用程序,该应用程序正在连接到外部域。
将以下代码添加到 Global.asax 中解决了问题:
protected void Application_Start()
{
AntiForgeryConfig.SuppressXFrameOptionsHeader = true;
}
我已经为 Microsoft Teams 创建了一个选项卡。添加到频道后显示错误:
Refused to display 'URL' in a frame because it set 'X-Frame-Options' to 'sameorigin'.
该选项卡应该加载托管在 Azure 中的应用程序,该应用程序正在连接到外部域。
将以下代码添加到 Global.asax 中解决了问题:
protected void Application_Start()
{
AntiForgeryConfig.SuppressXFrameOptionsHeader = true;
}