-
- Downloads
Add CSS class "removeIfDocumentRenderedInFrame" for <header> and <footer>
All DOM nodes of the CSS class "removeIfDocumentRenderedInFrame" are
removed from the DOM tree on DOMContentLoaded using JS.
We use this to hide/remove the <header> and <footer> from HTML pages
if they are rendered within a frame, for example an <iframe>.
Without this, our error pages look ugly and confusing in some
circumstances (for example, if /uv/uv.html is missing for some reason).
Signed-off-by:
Pascal Ernster <pascal.ernster@rub.de>
parent
6cf3e01d
Branches fix-http-status-codes
No related tags found
Showing
- hyrax/app/assets/javascripts/application.js 4 additions, 1 deletionhyrax/app/assets/javascripts/application.js
- hyrax/app/assets/javascripts/removeIfDocumentRenderedInFrame.js 21 additions, 0 deletions...app/assets/javascripts/removeIfDocumentRenderedInFrame.js
- hyrax/app/views/_masthead.html.erb 1 addition, 1 deletionhyrax/app/views/_masthead.html.erb
- hyrax/app/views/shared/_footer.html.erb 1 addition, 1 deletionhyrax/app/views/shared/_footer.html.erb
Please register or sign in to comment