https://discuss.newrelic.com/t/disabling-apm-for-google-amp-pages/36094/1
Last active
July 7, 2016 21:59
-
-
Save z4y4ts/43ed522cd8ad293f80997e9ad562f399 to your computer and use it in GitHub Desktop.
Disabling NewRelic APM for AMP pages
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 | |
add_action( 'pre_amp_render_post', 'xyz_amp_add_custom_actions' ); | |
function xyz_amp_add_custom_actions() { | |
if (extension_loaded('newrelic')) { | |
newrelic_disable_autorum(); | |
newrelic_ignore_transaction(); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment