Created
November 19, 2022 17:04
-
-
Save kreamweb/6d090660b23a77d5d0237444d57197ac to your computer and use it in GitHub Desktop.
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( 'admin_enqueue_scripts', 'ywpi_pdf_template_licence_key', 99 ); | |
if ( ! function_exists( 'ywpi_pdf_template_licence_key' ) ) { | |
function ywpi_pdf_template_licence_key() { | |
$js = "wp.hooks.addFilter('ywpi_pdf_template_demo', 'yith-woocommerce-pdf-invoice/customization', (key) => { | |
return 'ywpi_live_demo'; | |
} );"; | |
wp_add_inline_script( 'ywpi-pdf-template-builder-script', $js, 'after' ); | |
} | |
} | |
add_action( 'admin_enqueue_scripts', 'ywraq_pdf_template_licence_key', 99 ); | |
if ( ! function_exists( 'ywraq_pdf_template_licence_key' ) ) { | |
function ywraq_pdf_template_licence_key() { | |
$js = "wp.hooks.addFilter('ywraq_pdf_template_demo', 'yith-woocommerce-request-a-quote/customization', (key) => { | |
return 'ywraq_live_demo'; | |
} );"; | |
wp_add_inline_script( 'ywraq-pdf-template-builder-script', $js, 'after' ); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment