diff --git a/app/controllers/public/api/v1/portals/base_controller.rb b/app/controllers/public/api/v1/portals/base_controller.rb index 851b8c549..68619baf8 100644 --- a/app/controllers/public/api/v1/portals/base_controller.rb +++ b/app/controllers/public/api/v1/portals/base_controller.rb @@ -1,6 +1,7 @@ class Public::Api::V1::Portals::BaseController < PublicController before_action :show_plain_layout around_action :set_locale + after_action :allow_iframe_requests private @@ -39,4 +40,8 @@ class Public::Api::V1::Portals::BaseController < PublicController I18n.with_locale(@locale, &) end + + def allow_iframe_requests + response.headers.delete('X-Frame-Options') if @is_plain_layout_enabled + end end diff --git a/app/views/public/api/v1/portals/articles/show.html.erb b/app/views/public/api/v1/portals/articles/show.html.erb index 62e05a900..9423c42e5 100644 --- a/app/views/public/api/v1/portals/articles/show.html.erb +++ b/app/views/public/api/v1/portals/articles/show.html.erb @@ -37,13 +37,13 @@ <% else %> -