Created
October 30, 2025 14:02
-
-
Save xlplugins/47befa8bfee03f36e6a45e99a60419bd to your computer and use it in GitHub Desktop.
disable_country_code_optin.php
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
| class WFACP_Compatibility_CountryCodeFor_Elementor_Form_Telephone { | |
| public function __construct() { | |
| add_action( 'wp', [ $this, 'deque_script_optin' ] ); | |
| } | |
| public function deque_script_optin() { | |
| if ( ! WFOPP_Core()->optin_pages->is_wfop_page() ) { | |
| return; | |
| } | |
| add_action( 'wp_enqueue_scripts', function () { | |
| wp_deregister_script( 'ccfef-country-code-library-script' ); | |
| wp_deregister_script( 'ccfef-country-code-script' ); | |
| wp_deregister_style( 'ccfef-country-code-library-style' ); | |
| wp_deregister_style( 'ccfef-country-code-style' ); | |
| wp_dequeue_script( 'ccfef-country-code-library-script' ); | |
| wp_dequeue_script( 'ccfef-country-code-script' ); | |
| wp_dequeue_style( 'ccfef-country-code-library-style' ); | |
| wp_dequeue_style( 'ccfef-country-code-style' ); | |
| }, 9 ); | |
| } | |
| } | |
| new WFACP_Compatibility_CountryCodeFor_Elementor_Form_Telephone(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment