问题描述
我能够在IOS Messenger应用程序上使用Messenger Webview(配置为文档中所述),但在桌面浏览器中,webView总是在新页面中打开.
I am able to use Messenger webviews on the IOS Messenger app (configured as described in the documentation), but in the desktop browser the webViews always open in a new page.
我做错什么了吗,还是桌面Web浏览器中的Messenger根本不支持紧凑"或高"之类的Webview显示模式?
Am I doing something wrong, or does Messenger in desktop web browsers simply not support the webview display modes like "compact" or "tall"?
推荐答案
到目前为止,它已经可以使用了.要制作弹出式网络视图而不是打开新标签,您需要:
As of today, it is now doable.To make a pop-up webview instead of opening a new tab, you will need to:
1)设置适当的X-Frame-Options HTTP响应标头,以允许您的页面位于iframe中.
1) Set up proper X-Frame-Options HTTP response header to allow your pages within an iframe.
2)如果要从永久菜单中打开Web视图,则需要将"menu_item"对象的属性"messenger_extensions"的值设置为true.
2) If the webview is to be opened from the persistent menu, you will need to set the value of the property "messenger_extensions" of the "menu_item" object to true.
链接:
https://developers.facebook.com/docs/messenger-platform /webview/extensions https://developers.facebook.com/docs/messenger-platform/reference/messenger-profile-api/persistent-menu
这篇关于桌面浏览器是否支持Facebook Messenger弹出式Webview?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!