I am trying to embed the admin “new post” WordPress page into an iframe:
<iframe height="500px" frameborder="0" width="740px" src="my_wordpress_domain/wp-admin/post-new.php"/>
For some reason the iframe loads a blank page. The link itself works in a separate tab and so does the wordpress home page.
Is this a security issue, if so, how can I circumvent it?
By default WordPress doesnât allow to embed the admin pages into a frame. From
wp-includes/default-filters.php
:To enable embedding, remove the action in a plugin:
Be aware of the security implications. I wouldnât do that.
There’s no straight forward way around this if you are using wordpress.com hosted page. If you have independent hosting, make sure you enter this in the html page, or consider one of the iframe plugins. I use iframe embedder.