Last active
September 14, 2022 11:17
-
-
Save danielbitzer/eda493e1ba567328bf58f56e76433185 to your computer and use it in GitHub Desktop.
AutomateWoo - Allow click tracking to external hosts
This file contains hidden or 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 | |
/** | |
* Adding a domain to the 'allowed_redirect_hosts' filter means AutomateWoo will use click tracking for URLs | |
* on this domain. Otherwise only URLs matching the site's domain will use click tracking for security reasons. | |
* | |
* @param array $hosts | |
* @return array | |
*/ | |
add_filter( 'allowed_redirect_hosts', function( $hosts ) { | |
$hosts[] = 'example.org'; | |
return $hosts; | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment