首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >将H5P从Wordpress嵌入到R Bookdown

将H5P从Wordpress嵌入到R Bookdown
EN

Stack Overflow用户
提问于 2022-09-29 08:54:32
回答 1查看 40关注 0票数 0

我尝试将交互式H5P特性添加到我的bookdown中。

你可以在这本书上看到他们

https://www.bookdown.org/pbaumgartner/itns-exercises/chapter-01.html

看看作者如何将托管在Wordpress站点https://github.com/petzi53/itns-exercises/blob/master/001-research-questions.Rmd上的https://github.com/petzi53/itns-exercises/blob/master/001-research-questions.Rmd元素嵌入到iframe中,就像这样的<iframe src="https://peter.baumgartner.name/wp-admin/admin-ajax.php?action=h5p_embed&id=49" width="958" height="665" frameborder="0" allowfullscreen="allowfullscreen"></iframe><script src="https://peter.baumgartner.name/wp-content/plugins/h5p/h5p-php-library/js/h5p-resizer.js" charset="UTF-8"></script>

我设法嵌入了H5P iframe,当它来自https://h5p.org时,就像这样

<iframe src="https://h5p.org/h5p/embed/1295995" width="1090" height="245" frameborder="0" allowfullscreen="allowfullscreen" allow="geolocation *; microphone *; camera *; midi *; encrypted-media *" title="SOEP Intrpduction"></iframe><script src="https://h5p.org/sites/all/modules/h5p/library/js/h5p-resizer.js" charset="UTF-8"></script>

我的网站embed&id=2上有一个embed&id=2元素,但是当嵌入浏览器时

“网站将不允许火狐显示该网页,如果另一个网站已嵌入它”

问题似乎在我的服务器上。有人知道如何配置服务器以允许嵌入此H5P元素吗?谢谢

EN

回答 1

Stack Overflow用户

发布于 2022-10-01 09:16:46

您的服务器配置为不允许将其内容嵌入到其他站点--它正在将所谓的X-框架-选项设置为sameorigin。您需要通过设置一个内容安全策略来解决这个问题。

顺便说一下,如果你点击“了解更多”,火狐就会提示这个问题。

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/73892818

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档