e noscript iframe while keeping the data layer active - e.g. * from an mu-plugin on a staging/clone copy of the site. * * @since 2.0.0 * * @param bool $output_container Whether to output the container. Default true. */ if ( ! apply_filters( GTM4WP_WPFILTER_OUTPUT_CONTAINER, true ) ) { return false; } if ( $this->options->get( GTM4WP_OPTION_PRODUCTIONONLY ) ) { // wp_get_environment_type() ships with WordPress 5.5+; the guard // keeps the unit tests (which never load WordPress) working. $environment = function_exists( 'wp_get_environment_type' ) ? wp_get_environment_type() : 'production'; if ( 'production' !== $environment ) { return false; } } return true; } /** * Returns the first role of the current user that the "Exclude user roles" * option turns the container code off for, or an empty string when the * container may be emitted for this user. * * Both container sinks ask this - the loader in header_begin() and * the