看板 Ruby 關於我們 聯絡資訊
我是用rails 5.0.2版 想用youtube 上的分享 分享會用到IFRAME 但是在SHOW的時候iFream沒有辦法顯示 GOOGLE上找到的解答是從 config/application.rb中加入 config.action_dispatch.default_headers.merge!({'X-Frame-Options' => 'ALLOWALL'}) 也有試過從controller中加入 response.headers.except! 'X-Frame-Options' response.headers['X-Frame-Options'] = 'ALLOW-FROM https://www.youtube.com' 但是都不成功???? 有其他解法嗎? 我是在production 模式下 -- ※ 發信站: 批踢踢實業坊(ptt.cc), 來自: 27.52.193.187 ※ 文章網址: https://www.ptt.cc/bbs/Ruby/M.1493977417.A.5B5.html
retsamsu: 不要用這個方法,有 Clickjacking 弱點 05/08 12:47