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 | |
| // Display Input Field on Backend | |
| add_action( 'woocommerce_product_options_general_product_data', function () { | |
| global $woocommerce, $post; | |
| echo '<div class="options_group">'; | |
| woocommerce_wp_text_input( | |
| array( | |
| 'id' => 'product_key_features', | |
| 'label' => __( 'Product Key Features', 'woocommerce' ), | |
| 'placeholder' => 'Enter product key features (3 words)', |
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
| $mail->SMTPOptions = array( | |
| 'ssl' => array( | |
| 'verify_peer' => false, | |
| 'verify_peer_name' => false, | |
| 'allow_self_signed' => true | |
| ) | |
| ); |
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 | |
| /** | |
| * Admin new order email | |
| */ | |
| $order = new WC_order( $item_data->order_id ); | |
| echo "= " . $email_heading . " =\n\n"; | |
| $opening_paragraph = __( 'A new order has been made by %s. The details of the item are as follows:', 'custom-email' ); |
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 | |
| /** | |
| * Admin new order email | |
| */ | |
| $order = new WC_order( $item_data->order_id ); | |
| $opening_paragraph = __( 'A new order has been made by %s. The details of the item are as follows:', 'custom-email' ); | |
| ?> | |
| <?php do_action( 'woocommerce_email_header', $email_heading ); ?> |
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 | |
| /** | |
| * Handles email sending | |
| */ | |
| class Custom_Email_Manager { | |
| /** | |
| * Constructor sets up actions | |
| */ | |
| public function __construct() { |
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 | |
| //response generation function | |
| $response = ""; | |
| //function to generate response | |
| function my_contact_form_generate_response($type, $message){ | |
| global $response; |
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 | |
| /** | |
| * Contact form functionality | |
| * Used within the loop | |
| * @link https://developer.wordpress.org/reference/functions/wp_nonce_field/ | |
| * @link https://codex.wordpress.org/Class_Reference/WP_Error | |
| * @link https://developer.wordpress.org/reference/functions/wp_is_mobile/ | |
| * @link https://developer.wordpress.org/reference/functions/wp_kses_data/ | |
| * @link https://developer.wordpress.org/reference/functions/wp_remote_retrieve_response_code/ | |
| * @link https://developer.wordpress.org/reference/functions/wp_get_referer/ |
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 | |
| /** | |
| * Contact form functionality | |
| * Used within the loop | |
| * @link https://developer.wordpress.org/reference/functions/wp_nonce_field/ | |
| * @link https://codex.wordpress.org/Class_Reference/WP_Error | |
| */ | |
| defined( 'ABSPATH' ) or die( 'No script kiddies please!' ); |
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
| /*****************************************************/ | |
| /******** WOO CART / CHECKOUT / ACCOUNT PAGES ********/ | |
| /*****************************************************/ | |
| /*** MAIN FORMS BACKGROUND COLOR ***/ | |
| .woocommerce table.shop_table, | |
| .woocommerce form.checkout_coupon, | |
| .woocommerce form.login, | |
| .woocommerce form.register, | |
| #add_payment_method #payment, |
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 // For implementation instructions see: https://aceplugins.com/how-to-add-a-code-snippet/ | |
| /** | |
| * Add link icons. | |
| * | |
| * Adds a external-link icon to external links only. | |
| */ | |
| function ace_add_external_link_icon( ) { | |
| wp_register_script( 'external-link-icon', false ); | |
| wp_enqueue_script( 'external-link-icon' ); |