function custom_woo_ce_extend_product_fields( $fields ) { $fields[] = array( ‘name’ => ‘models’, ‘label’ => __( ‘Models’, ‘woo_ce’ ), ‘hover’ => __( ‘Models within functions.php’, ‘woo_ce’ ) ); return $fields; } add_filter( ‘woo_ce_product_fields’, ‘custom_woo_ce_extend_product_fields’ ); function custom_woo_ce_extend_product_item( $product, $product_id ) { $term_taxonomy…Continue reading
function custom_woo_ce_scheduled_export_orders_filter_by_custom_meta( $post_ID = 0 ) { // This is the Order meta key we want to filter Orders by, it also forms part of the Filter Orders by… label $meta_key = ‘_shipping_postcode’; // This is the saved Order meta…Continue reading
function custom_woo_ce_failed_scheduled_export( $scheduled_export, $error = ” ) { // Send an e-mail on failed Scheduled Exports $to = ‘[email protected]’; $subject = sprintf( ‘Scheduled Export %s failed to complete’, get_the_title( $scheduled_export ) ); $message = sprintf( ‘Scheduled Export %s (Post ID:…Continue reading
function custom_woo_ce_extend_order_fields( $fields ) { $fields[] = array( ‘name’ => ‘user_description’, ‘label’ => ‘Biographical Info’, ‘hover’ => ‘Custom User field within functions.php’ ); return $fields; } add_filter( ‘woo_ce_order_fields’, ‘custom_woo_ce_extend_order_fields’ ); function custom_woo_ce_extend_order( $order ) { if( !empty( $order->user_id ) )…Continue reading
function custom_woo_ce_extend_subscription_fields( $fields ) { $fields[] = array( ‘name’ => ‘paypal_subscriber_id’, ‘label’ => __( ‘PayPal Subscriber ID’, ‘woo_ce’ ), ‘hover’ => __( ‘PayPal Subscriber ID within functions.php’, ‘woo_ce’ ) ); return $fields; } add_filter( ‘woo_ce_subscription_fields’, ‘custom_woo_ce_extend_subscription_fields’ ); function custom_woo_ce_subscription_extend( $subscription,…Continue reading
function custom_woo_ce_extend_order_fields( $fields ) { $fields[] = array( ‘name’ => ‘order_modified’, ‘label’ => ‘Last Modified’, ‘hover’ => ‘Last Modified field within functions.php’ ); return $fields; } add_filter( ‘woo_ce_order_fields’, ‘custom_woo_ce_extend_order_fields’ ); function custom_woo_ce_extend_order( $order, $order_id ) { $date_format = woo_ce_get_option( ‘date_format’,…Continue reading
function custom_woo_ce_cron_export_email_wp_mail_failure_notice() { // Turn off the error notice return false; } add_filter( ‘woo_ce_cron_export_email_wp_mail_failure_notice’, ‘custom_woo_ce_cron_export_email_wp_mail_failure_notice’ );Continue reading
function custom_woo_ce_extend_product_fields( $fields ) { $fields[] = array( ‘name’ => ‘fruit’, ‘label’ => __( ‘Fruit’, ‘woo_ce’ ), ‘hover’ => __( ‘Fruit within functions.php’, ‘woo_ce’ ) ); $fields[] = array( ‘name’ => ‘vegetable’, ‘label’ => __( ‘Vegetable’, ‘woo_ce’ ), ‘hover’ =>…Continue reading
function custom_woo_ce_get_extra_product_option_value_formatting( $output, $tm_field, $order_item ) { $output = sprintf( __( ‘Value: %s’, ‘woocommerce-exporter’ ), $tm_field[‘value’] ) . “\n” . sprintf( __( ‘Price: %s’, ‘woocommerce-exporter’ ), woo_ce_format_price( $tm_field[‘price’] ) ) . “\n” . sprintf( __( ‘Quantity: %s’, ‘woocommerce-exporter’ ), $tm_field[‘quantity’]…Continue reading
function custom_woo_ce_export_phpexcel_caching_methods() { $cacheSettings = array( ‘memoryCacheSize ‘ => ‘8MB’ ); // Cache to phpTemp $cacheMethod = PHPExcel_CachedObjectStorageFactory::cache_to_phpTemp; // Cache in memory; gzip // $cacheMethod = PHPExcel_CachedObjectStorageFactory::cache_in_memory_gzip; // Cache in memory; serialized // $cacheMethod = PHPExcel_CachedObjectStorageFactory::cache_in_memory_serialized; // Cache in memory;…Continue reading