-
-
Save torbentschechne/d2d412109403495d18efdad0821eb31a to your computer and use it in GitHub Desktop.
WooCommerce - Allow rendering of checkout and account pages in iframes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php // Do not include this if already open! | |
/** | |
* Code goes in theme functions.php. | |
*/ | |
add_action( 'after_setup_theme', 'wc_remove_frame_options_header', 11 ); | |
/** | |
* Allow rendering of checkout and account pages in iframes. | |
*/ | |
function wc_remove_frame_options_header() { | |
remove_action( 'template_redirect', 'wc_send_frame_options_header' ); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment