Using iframe or script tag in the gitlab wiki



I would like to embed in my wiki page. Can I embed iframe or script tags in my gitlab wiki pages?

Or do I have to change the sanitization filter?




I figured it out myself:

The following statements have to be added to .../gitlab/markdown/sanitization_filter.rb

# allow script tag and src attribute
whitelist[:attributes]['script'] = %w(src)

Then run gitlab-ctl reconfigure.

Please also have look at the docs:


I tried to get this to work, and I can’t seem to get it. It just doesn’t show/display the iframe.


Iframe is not a solution (is not possible if you dont want to break the auth system), I have to try a, is a excellent piece of code but is like kill a fly with a gun.


Hi @ tobiasschweizer
Where can I access .../gitlab/markdown/sanitization_filter.rb to change it?