Live Preview link not working

I’m facing a weird issue with the demo of my theme. The link to the demo is https://avocet.superavis.com/.

If you go to the item page (https://themeforest.net/item/avocet-wordpress-blog-theme-for-lifestyle-food-travel-and-fashion-bloggers/13851747) and click on Live Preview, it says “avocet.superavis.com refused the connection”. However, if you click on the “Remove Frame” button on the top right side, it works fine. What could be the issue?

Hi @SuperAvis!

This is because your demo URL is sending back the following header:
x-frame-options: sameorigin

This is a security feature that only allows pages hosted at the same origin (on avocet.superavis.com) to embed that page in an iframe. See the documentation at MDN.

In order to fix this, you’ll need to configure your webserver to not send that header for your demo page(s).

1 Like

Removing it from header fixed it. Thank you for pointing it out :slight_smile:

1 Like