Server IP : 172.67.158.161 / Your IP : 3.133.118.163 Web Server : LiteSpeed System : Linux business53.web-hosting.com 4.18.0-553.lve.el8.x86_64 #1 SMP Mon May 27 15:27:34 UTC 2024 x86_64 User : giankuin ( 1871) PHP Version : 7.4.33 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : OFF | Pkexec : OFF Directory : /home/giankuin/dietcontrungnhanh.com/wp-content/plugins/ithemes-security-pro/pro/passwordless-login/integrations/ |
Upload File : |
<?php namespace iThemesSecurity\PasswordlessLogin\Integrations; use iThemesSecurity\PasswordlessLogin\Integration\Integration; class EasyDigitalDownloads implements Integration { public function get_name() { return 'Easy Digital Downloads'; } public function get_slug() { return 'edd'; } public function run() { add_action( 'edd_login_fields_before', [ $this, 'render_passwordless_link' ] ); add_action( 'edd_checkout_login_fields_before', [ $this, 'render_passwordless_link' ] ); add_action( 'wp_enqueue_scripts', [ $this, 'include_script_on_checkout' ] ); } public function render_passwordless_link() { $redirect_to = ''; if ( wp_doing_ajax() && $_REQUEST['action'] === 'checkout_login' ) { $redirect_to = edd_get_checkout_uri(); } ?> <p><?php echo \ITSEC_Passwordless_Login_Utilities::render_modal_link( $redirect_to ); ?></p> <?php } public function include_script_on_checkout() { if ( edd_is_checkout() ) { \ITSEC_Passwordless_Login_Utilities::enqueue_modal_scripts(); } } }