Reputation: 1
I am new to Django. I have launched a new site with Django. I wish people can iframe my site. But when doing I frame, It shows Site Refused to connect. . As a newbie, I don’t have any idea what to do now. Would you please suggest me.
Upvotes: 0
Views: 1741
Reputation: 3910
Django 3.0(https://docs.djangoproject.com/en/3.1/releases/3.0/#security) update disabled X_FRAME_OPTIONS to DENY in settings.py. You can add the domain you want to show iframe in
X_FRAME_OPTIONS = 'SAMEORIGIN'
Upvotes: 1