Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to integrate rails application by iframe #31

Open
dongtong opened this issue Nov 22, 2017 · 0 comments
Open

How to integrate rails application by iframe #31

dongtong opened this issue Nov 22, 2017 · 0 comments
Labels

Comments

@dongtong
Copy link
Owner

When we integrate rails application by iframe, the browser console will report "X-Frame-Options to SAMEORIGIN by default" error, so we should let rails application ignore iframe check in controller.

before_action :allow_iframe_requests

private

def allow_iframe_requests
    response.headers.delete('X-Frame-Options')
end
@dongtong dongtong added the Rails label Nov 22, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant