Changeset 3249938
- Timestamp:
- 03/03/2025 08:50:03 PM (11 months ago)
- Location:
- hippoo/trunk
- Files:
-
- 85 added
- 19 edited
-
app/pwa.php (added)
-
app/settings.php (modified) (5 diffs)
-
app/utils.php (modified) (1 diff)
-
app/web_api.php (modified) (7 diffs)
-
app/web_api_auth.php (modified) (2 diffs)
-
assets/css/admin-style.css (modified) (4 diffs)
-
assets/js/admin-script-copy.js (added)
-
assets/js/admin-script.js (modified) (1 diff)
-
hippoo.php (modified) (5 diffs)
-
invoice/api.php (modified) (1 diff)
-
invoice/assets/css/admin-style.css (modified) (1 diff)
-
invoice/main.php (modified) (3 diffs)
-
invoice/settings.php (modified) (27 diffs)
-
invoice/templates/simple/factor.php (modified) (10 diffs)
-
invoice/templates/simple/label.php (modified) (5 diffs)
-
invoice/web_api_auth.php (modified) (2 diffs)
-
invoice/woocommerce/my-account.php (modified) (3 diffs)
-
invoice/woocommerce/order-copy.php (added)
-
invoice/woocommerce/order-test.php (modified) (1 diff)
-
invoice/woocommerce/order.php (modified) (5 diffs)
-
invoice/woocommerce/product.php (modified) (3 diffs)
-
pwa (added)
-
pwa/.nojekyll (added)
-
pwa/200.html (added)
-
pwa/_nuxt (added)
-
pwa/_nuxt/05caade.js (added)
-
pwa/_nuxt/22f435c.js (added)
-
pwa/_nuxt/25b4adb.js (added)
-
pwa/_nuxt/269e722.js (added)
-
pwa/_nuxt/487b17a.js (added)
-
pwa/_nuxt/5de6059.js (added)
-
pwa/_nuxt/6354f4d.js (added)
-
pwa/_nuxt/63574a1.js (added)
-
pwa/_nuxt/815057c.js (added)
-
pwa/_nuxt/9803c09.js (added)
-
pwa/_nuxt/LICENSES (added)
-
pwa/_nuxt/a1dfeea.js (added)
-
pwa/_nuxt/ca2901c.js (added)
-
pwa/_nuxt/css (added)
-
pwa/_nuxt/css/5af39bb.css (added)
-
pwa/_nuxt/css/925afd8.css (added)
-
pwa/_nuxt/css/d6a4ea1.css (added)
-
pwa/_nuxt/e7ae1bb.js (added)
-
pwa/_nuxt/manifest.ae04bb04.json (added)
-
pwa/_nuxt/manifest.f69fa5fb.json (added)
-
pwa/fonts (added)
-
pwa/fonts/icons.eot (added)
-
pwa/fonts/icons.svg (added)
-
pwa/fonts/icons.ttf (added)
-
pwa/fonts/icons.woff (added)
-
pwa/fonts/ttf (added)
-
pwa/fonts/ttf/PlusJakartaSans-Bold.ttf (added)
-
pwa/fonts/ttf/PlusJakartaSans-Medium.ttf (added)
-
pwa/fonts/ttf/PlusJakartaSans-Regular.ttf (added)
-
pwa/fonts/ttf/PlusJakartaSans-SemiBold.ttf (added)
-
pwa/img (added)
-
pwa/img/app-icons (added)
-
pwa/img/app-icons/icon-120.png (added)
-
pwa/img/app-icons/icon-144.png (added)
-
pwa/img/app-icons/icon-152.png (added)
-
pwa/img/app-icons/icon-192.png (added)
-
pwa/img/app-icons/icon-256.png (added)
-
pwa/img/app-icons/icon-384.png (added)
-
pwa/img/app-icons/icon-512.png (added)
-
pwa/img/app-icons/icon-64.png (added)
-
pwa/img/favicon.ico (added)
-
pwa/img/logo.png (added)
-
pwa/img/no-image.jpg (added)
-
pwa/index.html (added)
-
pwa/robot.txt (added)
-
pwa/sw.js (added)
-
pwa/workbox (added)
-
pwa/workbox/workbox-background-sync.dev.js (added)
-
pwa/workbox/workbox-background-sync.prod.js (added)
-
pwa/workbox/workbox-broadcast-update.dev.js (added)
-
pwa/workbox/workbox-broadcast-update.prod.js (added)
-
pwa/workbox/workbox-cacheable-response.dev.js (added)
-
pwa/workbox/workbox-cacheable-response.prod.js (added)
-
pwa/workbox/workbox-core.dev.js (added)
-
pwa/workbox/workbox-core.prod.js (added)
-
pwa/workbox/workbox-expiration.dev.js (added)
-
pwa/workbox/workbox-expiration.prod.js (added)
-
pwa/workbox/workbox-navigation-preload.dev.js (added)
-
pwa/workbox/workbox-navigation-preload.prod.js (added)
-
pwa/workbox/workbox-offline-ga.dev.js (added)
-
pwa/workbox/workbox-offline-ga.prod.js (added)
-
pwa/workbox/workbox-precaching.dev.js (added)
-
pwa/workbox/workbox-precaching.prod.js (added)
-
pwa/workbox/workbox-range-requests.dev.js (added)
-
pwa/workbox/workbox-range-requests.prod.js (added)
-
pwa/workbox/workbox-routing.dev.js (added)
-
pwa/workbox/workbox-routing.prod.js (added)
-
pwa/workbox/workbox-strategies.dev.js (added)
-
pwa/workbox/workbox-strategies.prod.js (added)
-
pwa/workbox/workbox-streams.dev.js (added)
-
pwa/workbox/workbox-streams.prod.js (added)
-
pwa/workbox/workbox-sw.js (added)
-
pwa/workbox/workbox-window.dev.es5.mjs (added)
-
pwa/workbox/workbox-window.dev.mjs (added)
-
pwa/workbox/workbox-window.dev.umd.js (added)
-
pwa/workbox/workbox-window.prod.es5.mjs (added)
-
pwa/workbox/workbox-window.prod.mjs (added)
-
pwa/workbox/workbox-window.prod.umd.js (added)
-
readme.txt (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
hippoo/trunk/app/settings.php
r3237006 r3249938 1 <?php 1 <?php // phpcs:disable PluginCheck.CodeAnalysis.ImageFunctions.NonEnqueuedImage 2 2 3 3 class HippooSettings … … 28 28 public function settings_init() 29 29 { 30 register_setting('hippoo_settings', $this->slug); 30 register_setting('hippoo_settings', $this->slug); // phpcs:ignore 31 31 32 32 add_settings_section( 33 33 'hippoo_invoice_settings_section', 34 __('Hippoo invoice extension', 'hippoo'),34 null, 35 35 null, 36 36 $this->slug 37 37 ); 38 38 39 $description = '<p>' . esc_html__( 'Provides PDF invoices and shipping labels for easy printing. Also generates barcodes for orders and product SKUs inside the WooCommerce dashboard, allowing you to scan them with the Hippoo WooCommerce app\'s barcode scanner to quickly find orders and products.', 'hippoo' ) . '</p>'; 39 40 add_settings_field( 40 41 'invoice_plugin_enabled', 41 __('Enable Hippoo invoice and shipping label', 'hippoo') ,42 __('Enable Hippoo invoice and shipping label', 'hippoo') . $description, 42 43 array($this, 'invoice_plugin_enabled_render'), 43 44 $this->slug, … … 46 47 } 47 48 48 /***** Helper Function *****/49 public function render_checkbox_input($name, $value_key) {50 $value = isset($this->settings[$value_key]) ? $this->settings[$value_key] : 0;51 ?>52 <input type="checkbox" class="switch" name="hippoo_invoice_settings[<?php echo esc_attr($name); ?>]" <?php checked($value, 1); ?> value="1">53 <?php54 }49 /***** Helper Function *****/ 50 public function render_checkbox_input($name, $value_key) { 51 $value = isset($this->settings[$value_key]) ? $this->settings[$value_key] : 0; 52 ?> 53 <input type="checkbox" class="switch" name="hippoo_invoice_settings[<?php echo esc_attr($name); ?>]" <?php checked($value, 1); ?> value="1"> 54 <?php 55 } 55 56 56 57 public function invoice_plugin_enabled_render() 57 58 { 58 59 $value = isset($this->settings['invoice_plugin_enabled']) ? $this->settings['invoice_plugin_enabled'] : 0; 59 ?>60 ?> 60 61 <input type="checkbox" class="switch" name="hippoo_settings[invoice_plugin_enabled]" <?php checked($value, 1); ?> value="1"> 61 62 <?php … … 65 66 { 66 67 ?> 67 < <form id="hippoo_settings" action="options.php" method="post">68 <h2><?php esc_html_e('Hippoo Settings', 'hippoo -setting'); ?></h2>68 <form id="hippoo_settings" action="options.php" method="post"> 69 <h2><?php esc_html_e('Hippoo Settings', 'hippoo'); ?></h2> 69 70 <div class="tabs"> 70 71 <h2 class="nav-tab-wrapper"> … … 124 125 125 126 new HippooSettings(); 126 ?> -
hippoo/trunk/app/utils.php
r3117864 r3249938 3 3 $wp_upload_dir = wp_upload_dir(); 4 4 $temp_dir = implode( DIRECTORY_SEPARATOR, [ $wp_upload_dir['basedir'], 'hippoo', 'tmp' ] ) . DIRECTORY_SEPARATOR; 5 5 6 if (!file_exists($temp_dir)) { 7 // phpcs:ignore 6 8 mkdir($temp_dir, 0755, true); 7 9 } -
hippoo/trunk/app/web_api.php
r3237006 r3249938 8 8 9 9 function hippoo_woocommerce_no_stock_notification($product){ 10 update_post_meta($product->get_id(), 'out_stock_time', date('Y-m-d H:i:s'));10 update_post_meta($product->get_id(), 'out_stock_time', gmdate('Y-m-d H:i:s')); 11 11 hippoo_out_of_stock_send_notification_by_prodcut($product); 12 12 } … … 113 113 114 114 $home_url = home_url(); 115 $parsed_url = parse_url($home_url);115 $parsed_url = wp_parse_url($home_url); 116 116 $cs_hostname = $parsed_url['host']; 117 117 … … 149 149 150 150 $home_url = home_url(); 151 $parsed_url = parse_url($home_url);151 $parsed_url = wp_parse_url($home_url); 152 152 $cs_hostname = $parsed_url['host']; 153 153 … … 180 180 function hippoo_get_token_from_wc() 181 181 { 182 $key = md5(microtime(). rand());182 $key = md5(microtime().wp_rand()); 183 183 $store_url = get_option('siteurl'); 184 184 $store_url = str_replace("http://", "https://", $store_url); … … 230 230 { 231 231 if (time() - filemtime($t) > 20000) { 232 unlink($t);232 wp_delete_file($t); 233 233 } 234 234 } … … 242 242 if (file_exists($file)) { 243 243 $token = file_get_contents($file); 244 unlink($file);244 wp_delete_file($file); 245 245 $token_json = json_decode($token); 246 246 return new WP_REST_Response ($token_json, 200); … … 407 407 408 408 409 /* 410 * WC Store Settings API Route 411 */ 412 add_action( 'rest_api_init', function () { 413 414 register_rest_route( 'wc/store/v1', 'settings', array( 415 'methods' => 'GET', 416 'callback' => 'hippoo_wc_store_settings', 417 'permission_callback' => '__return_true', 418 )); 419 420 } ); 421 422 function hippoo_wc_store_settings() { 423 $shop_title = get_bloginfo('name'); 424 $cart_url = wc_get_cart_url(); 425 $base_url = get_site_url(); 426 427 $response_data = array( 428 'shop_title' => $shop_title, 429 'cart_url' => $cart_url, 430 'base_url' => $base_url, 431 ); 432 433 return new WP_REST_Response($response_data, 200); 434 } -
hippoo/trunk/app/web_api_auth.php
r3237006 r3249938 116 116 $page = --$page * 25; 117 117 global $wpdb; 118 $query = "SELECT p.ID as post_id, p.post_title, pm.meta_value as product_quantity, o.meta_value as out_of_stock_date 119 FROM $wpdb->posts AS p 120 JOIN $wpdb->postmeta AS pm ON p.ID = pm.post_id 121 JOIN $wpdb->postmeta AS o ON p.ID = o.post_id 122 WHERE p.post_type = 'product' 123 AND p.post_status = 'publish' 124 AND o.meta_key = 'out_stock_time' 125 AND pm.meta_key = '_stock' 126 AND pm.meta_value <= 0 127 ORDER BY out_of_stock_date DESC limit $page,25"; 128 $rows = $wpdb->get_results($wpdb->prepare($query)); 118 119 // phpcs:ignore 120 $rows = $wpdb->get_results( 121 $wpdb->prepare( 122 "SELECT p.ID as post_id, p.post_title, pm.meta_value as product_quantity, o.meta_value as out_of_stock_date 123 FROM $wpdb->posts AS p 124 JOIN $wpdb->postmeta AS pm ON p.ID = pm.post_id 125 JOIN $wpdb->postmeta AS o ON p.ID = o.post_id 126 WHERE p.post_type = 'product' 127 AND p.post_status = 'publish' 128 AND o.meta_key = 'out_stock_time' 129 AND pm.meta_key = '_stock' 130 AND pm.meta_value <= 0 131 ORDER BY out_of_stock_date DESC limit %d,25", 132 $page 133 ) 134 ); 129 135 130 136 if (empty($rows)) { … … 148 154 function hippoo_media_upload() 149 155 { 150 if (empty($_FILES['file'])) { 156 // phpcs:ignore 157 $file = isset($_FILES['file']) ? sanitize_text_field($_FILES['file']) : ''; 158 159 if (empty($file)) { 151 160 return new WP_Error('invalid_file', 'Invalid file.', ['status' => 400]); 152 161 } 153 $file = $_FILES['file'];162 154 163 $upload = wp_upload_bits($file['name'], null, file_get_contents($file['tmp_name'])); 155 164 -
hippoo/trunk/assets/css/admin-style.css
r3117864 r3249938 25 25 /* General Settigs */ 26 26 27 #hippoo_settings .form-table th { 27 #hippoo_settings .form-table { 28 max-width: 800px; 28 29 vertical-align: middle; 29 30 } … … 31 32 #hippoo_settings .form-table:first-of-type tr:first-child { 32 33 border-bottom: 1px solid #DFDFDF; 34 } 35 36 #hippoo_settings .form-table tr.disabled * { 37 color: #818181; 38 cursor: not-allowed; 33 39 } 34 40 … … 36 42 font-size: 16px; 37 43 font-weight: normal; 44 vertical-align: middle; 45 width: 100%; 46 } 47 48 #hippoo_settings .form-table td { 49 text-align: end; 50 vertical-align: top; 51 text-wrap: nowrap; 52 max-width: 100px; 53 } 54 55 #hippoo_settings .form-table td > * { 56 float: right; 38 57 } 39 58 … … 79 98 80 99 /* Form Elements */ 100 101 #hippoo_settings input[type="text"] { 102 width: 150px; 103 height: 39px; 104 } 81 105 82 106 #hippoo_settings select { -
hippoo/trunk/assets/js/admin-script.js
r3117864 r3249938 77 77 moveCarouselNext(); 78 78 }); 79 80 /* PWA */ 81 function toggleRouteNameField() { 82 if ($('#pwa_plugin_enabled').is(':checked')) { 83 $('#pwa_route_name').prop('disabled', false); 84 $('#pwa_route_name').closest('tr').removeClass('disabled'); 85 } else { 86 $('#pwa_route_name').prop('disabled', true); 87 $('#pwa_route_name').closest('tr').addClass('disabled'); 88 } 89 } 90 91 toggleRouteNameField(); 92 93 $(document).on('click', '#hippoo_settings #pwa_plugin_enabled', function() { 94 console.log("PWA checkbox clicked"); 95 toggleRouteNameField(); 96 }); 79 97 }); -
hippoo/trunk/hippoo.php
r3237006 r3249938 2 2 /** 3 3 * Plugin Name: Hippoo mobile app for woocommerce 4 * Version: 1.5. 04 * Version: 1.5.8 5 5 * Plugin URI: https://Hippoo.app/ 6 6 * Description: Best WooCommerce App Alternative – Manage orders and products on the go with real-time notifications, seamless order and product management, and powerful add-ons. Available for Android & iOS. 🚀. … … 30 30 } 31 31 32 define('hippoo_version', '1.5.8'); 32 33 define('hippoo_path', dirname(__file__).DIRECTORY_SEPARATOR); 33 34 define('hippoo_main_file_path', __file__); … … 41 42 include_once(hippoo_path.'app'.DIRECTORY_SEPARATOR.'web_api.php'); 42 43 include_once(hippoo_path.'app'.DIRECTORY_SEPARATOR.'settings.php'); 44 include_once(hippoo_path.'app'.DIRECTORY_SEPARATOR.'pwa.php'); 43 45 44 46 … … 48 50 add_action( 'after_setup_theme', 'hippoo_textdomain' ); 49 51 50 51 52 function hippoo_page_style( $hook ) { 52 wp_enqueue_style( 'hippoo-main-page-style', hippoo_url . "css/style.css", null, 1.0);53 wp_enqueue_style( 'hippoo-main-admin-style', hippoo_url . "css/admin-style.css", null, 1.0);54 wp_enqueue_script( 'hippoo-main-scripts', hippoo_url . "js/admin-script.js", [ 'jquery', 'jquery-ui-core', 'jquery-ui-tooltip' ] );53 wp_enqueue_style( 'hippoo-main-page-style', hippoo_url . "css/style.css", null, hippoo_version ); 54 wp_enqueue_style( 'hippoo-main-admin-style', hippoo_url . "css/admin-style.css", null, hippoo_version ); 55 wp_enqueue_script( 'hippoo-main-scripts', hippoo_url . "js/admin-script.js", [ 'jquery', 'jquery-ui-core', 'jquery-ui-tooltip' ], hippoo_version, true ); 55 56 } 56 57 add_action( 'admin_enqueue_scripts', 'hippoo_page_style' ); … … 99 100 update_option('hippoo_settings', $settings); 100 101 } 101 102 ?> -
hippoo/trunk/invoice/api.php
r3117864 r3249938 5 5 $controller->register_routes(); 6 6 }); 7 ?> -
hippoo/trunk/invoice/assets/css/admin-style.css
r3117864 r3249938 192 192 193 193 .barcode-tooltip { 194 position: relative;195 194 border: 1px solid #8B8B8B !important; 196 background : #FFFFFF !important;195 background-color: #FFFFFF !important; 197 196 box-shadow: 0px 4px 4px 0px rgba(0, 0, 0, 0.1) !important; 198 197 opacity: 1 !important; 199 198 text-align: center; 199 justify-items: center; 200 200 font-size: 18px; 201 201 padding: 10px 25px !important; -
hippoo/trunk/invoice/main.php
r3117864 r3249938 10 10 add_action( 'plugins_loaded', 'hippoo_load_textdomain' ); 11 11 function hippoo_load_textdomain() { 12 load_plugin_textdomain( 'hippoo-invoice', FALSE, HIPPOO_INVOICE_PLUGIN_LANG_DIR );12 load_plugin_textdomain( 'hippoo-invoice', false, HIPPOO_INVOICE_PLUGIN_LANG_DIR ); 13 13 } 14 14 add_action( 'admin_enqueue_scripts', 'hippoo_enqueue_scripts' ); 15 15 function hippoo_enqueue_scripts() { 16 wp_enqueue_style( 'hippoo-styles', HIPPOO_INVOICE_PLUGIN_URL . 'assets/css/admin-style.css' ); 17 wp_enqueue_script( 'hippoo-scripts', HIPPOO_INVOICE_PLUGIN_URL . 'assets/js/admin-script.js', [ 'jquery', 'jquery-ui-core', 'jquery-ui-tooltip' ] ); 16 wp_enqueue_style( 'hippoo-styles', HIPPOO_INVOICE_PLUGIN_URL . 'assets/css/admin-style.css', null, hippoo_version ); 17 wp_enqueue_script( 'hippoo-scripts', HIPPOO_INVOICE_PLUGIN_URL . 'assets/js/admin-script.js', [ 'jquery', 'jquery-ui-core', 'jquery-ui-tooltip' ], hippoo_version, true ); 18 } 19 add_action('admin_head', 'hippoo_force_admin_styles', 9999); 20 function hippoo_force_admin_styles() { 21 ?> 22 <style type="text/css"> 23 .barcode-tooltip { 24 background-color: #ffffff !important; 25 } 26 </style> 27 <?php 18 28 } 19 29 add_action( 'woocommerce_init', 'hippoo_invoice_load' ); 20 21 30 function hippoo_invoice_load() { 22 31 … … 42 51 add_filter( 'init', 'hippoo_handle_html_display' ); 43 52 function hippoo_handle_html_display() { 44 if ( isset( $_GET['download_type'] ) && isset( $_GET['post_id'] ) ) { 45 $post_id = sanitize_text_field( $_GET['post_id'] ); 46 $download_type = sanitize_text_field( $_GET['download_type'] ); 53 $_get = map_deep($_GET, 'sanitize_key'); // phpcs:ignore 54 55 if ( isset( $_get['download_type'] ) && isset( $_get['post_id'] ) ) { 56 $post_id = sanitize_text_field( $_get['post_id'] ); 57 $download_type = sanitize_text_field( $_get['download_type'] ); 47 58 48 59 if ( user_has_order_access( $post_id ) || current_user_can( 'administrator' ) ) { 49 60 $html_doc = generate_html( $post_id, $download_type ); 50 61 51 echo $html_doc;62 echo $html_doc; // phpcs:ignore 52 63 } else { 53 64 echo "You do not have access to view this order."; … … 56 67 } 57 68 } 58 59 ?> -
hippoo/trunk/invoice/settings.php
r3117864 r3249938 1 <?php 1 <?php // phpcs:disable PluginCheck.CodeAnalysis.ImageFunctions.NonEnqueuedImage 2 2 3 3 class HippooInvoiceSettings { … … 37 37 38 38 public function settings_init() { 39 register_setting( 'hippoo_invoice_settings', $this->slug );39 register_setting('hippoo_invoice_settings', $this->slug); // phpcs:ignore 40 40 41 41 $this->general_settings_init(); … … 48 48 <form id="hippoo_invoice_settings" action="options.php" method="post"> 49 49 <?php wp_nonce_field('hippoo_invoice_settings_save', 'hippoo_invoice_settings_nonce'); ?> 50 <h2><?php esc_html_e('Hippoo invoice and shipping label', 'hippoo -invoice'); ?></h2>50 <h2><?php esc_html_e('Hippoo invoice and shipping label', 'hippoo'); ?></h2> 51 51 52 52 <div class="tabs"> 53 53 <h2 class="nav-tab-wrapper"> 54 <a href="#tab-settings" class="nav-tab nav-tab-active"><?php esc_html_e('Settings', 'hippoo -invoice'); ?></a>54 <a href="#tab-settings" class="nav-tab nav-tab-active"><?php esc_html_e('Settings', 'hippoo'); ?></a> 55 55 </h2> 56 56 … … 71 71 add_settings_section( 72 72 'hippoo_general_settings_section', 73 __( 'General settings', 'hippoo -invoice' ),73 __( 'General settings', 'hippoo' ), 74 74 null, 75 75 $this->slug … … 78 78 add_settings_field( 79 79 'shop_logo', 80 __( 'Shop logo', 'hippoo -invoice' ),80 __( 'Shop logo', 'hippoo' ), 81 81 array( $this, 'shop_logo_render' ), 82 82 $this->slug, … … 86 86 add_settings_field( 87 87 'language_direction', 88 __( 'Language direction', 'hippoo -invoice' ),88 __( 'Language direction', 'hippoo' ), 89 89 array( $this, 'language_direction_render' ), 90 90 $this->slug, … … 94 94 add_settings_field( 95 95 'show_barcode_order_list', 96 __( 'Show barcode(Order id) in order list', 'hippoo -invoice' ),96 __( 'Show barcode(Order id) in order list', 'hippoo' ), 97 97 array( $this, 'show_barcode_order_list_render' ), 98 98 $this->slug, … … 102 102 add_settings_field( 103 103 'show_barcode_order_details', 104 __( 'Show barcode(Order id) in order details', 'hippoo -invoice' ),104 __( 'Show barcode(Order id) in order details', 'hippoo' ), 105 105 array( $this, 'show_barcode_order_details_render' ), 106 106 $this->slug, … … 110 110 add_settings_field( 111 111 'show_barcode_products_list', 112 __( 'Show barcode(SKU) in products list', 'hippoo -invoice' ),112 __( 'Show barcode(SKU) in products list', 'hippoo' ), 113 113 array( $this, 'show_barcode_products_list_render' ), 114 114 $this->slug, … … 118 118 add_settings_field( 119 119 'show_barcode_products_details', 120 __( 'Show barcode(SKU) in products details', 'hippoo -invoice' ),120 __( 'Show barcode(SKU) in products details', 'hippoo' ), 121 121 array( $this, 'show_barcode_products_details_render' ), 122 122 $this->slug, … … 128 128 add_settings_section( 129 129 'hippoo_invoice_settings_section', 130 __( 'Invoice settings', 'hippoo -invoice' ),130 __( 'Invoice settings', 'hippoo' ), 131 131 null, 132 132 $this->slug … … 136 136 add_settings_field( 137 137 'font_name', 138 __( 'Font name', 'hippoo -invoice' ),138 __( 'Font name', 'hippoo' ), 139 139 array( $this, 'font_name_render' ), 140 140 $this->slug, … … 144 144 add_settings_field( 145 145 'invoice_show_logo', 146 __( 'Show logo', 'hippoo -invoice' ),146 __( 'Show logo', 'hippoo' ), 147 147 array( $this, 'invoice_show_logo_render' ), 148 148 $this->slug, … … 152 152 add_settings_field( 153 153 'show_customer_note', 154 __( 'Show customer note', 'hippoo -invoice' ),154 __( 'Show customer note', 'hippoo' ), 155 155 array( $this, 'show_customer_note_render' ), 156 156 $this->slug, … … 160 160 add_settings_field( 161 161 'show_product_sku_invoice', 162 __( 'Show product SKU in invoice', 'hippoo -invoice' ),162 __( 'Show product SKU in invoice', 'hippoo' ), 163 163 array( $this, 'show_product_sku_invoice_render' ), 164 164 $this->slug, … … 168 168 add_settings_field( 169 169 'footer_description', 170 __( 'Footer description', 'hippoo -invoice' ),170 __( 'Footer description', 'hippoo' ), 171 171 array( $this, 'footer_description_render' ), 172 172 $this->slug, … … 178 178 add_settings_section( 179 179 'hippoo_shipping_settings_section', 180 __( 'Shipping label settings', 'hippoo -invoice' ),180 __( 'Shipping label settings', 'hippoo' ), 181 181 null, 182 182 $this->slug … … 186 186 add_settings_field( 187 187 'shipping_show_logo', 188 __( 'Show logo', 'hippoo -invoice' ),188 __( 'Show logo', 'hippoo' ), 189 189 array( $this, 'shipping_show_logo_render' ), 190 190 $this->slug, … … 194 194 add_settings_field( 195 195 'shipping_calculate_weight', 196 __( 'Calculate Weight', 'hippoo -invoice' ),196 __( 'Calculate Weight', 'hippoo' ), 197 197 array( $this, 'shipping_calculate_weight_render' ), 198 198 $this->slug, … … 202 202 add_settings_field( 203 203 'shipping_courier_logo', 204 __( 'Courier logo', 'hippoo -invoice' ),204 __( 'Courier logo', 'hippoo' ), 205 205 array( $this, 'shipping_courier_logo_render' ), 206 206 $this->slug, … … 226 226 <div class="uploader"> 227 227 <input type="hidden" id="shop_logo_field" name="hippoo_invoice_settings[shop_logo]" value="<?php echo esc_url($image_url); ?>" /> 228 <img id="shop_logo" src="<?php echo esc_url($image_url); ?>" width="64" height="64" alt="<?php esc_attr_e('Shop Logo', 'hippoo -invoice'); ?>" />228 <img id="shop_logo" src="<?php echo esc_url($image_url); ?>" width="64" height="64" alt="<?php esc_attr_e('Shop Logo', 'hippoo'); ?>" /> 229 229 <div class="upload_buttons"> 230 <button id="shop_logo_upload_button" class="button upload"><?php esc_html_e('Upload Logo', 'hippoo -invoice'); ?></button>231 <button id="shop_logo_clear_button" class="button remove"><?php esc_html_e('Remove', 'hippoo -invoice'); ?></button>232 <p class="desc"><?php esc_html_e('512x512 is perfect size for logo', 'hippoo -invoice'); ?></p>230 <button id="shop_logo_upload_button" class="button upload"><?php esc_html_e('Upload Logo', 'hippoo'); ?></button> 231 <button id="shop_logo_clear_button" class="button remove"><?php esc_html_e('Remove', 'hippoo'); ?></button> 232 <p class="desc"><?php esc_html_e('512x512 is perfect size for logo', 'hippoo'); ?></p> 233 233 </div> 234 234 </div> … … 251 251 foreach ( $options as $value => $label ) { 252 252 $selected_attr = selected( $selected, $value, false ); 253 echo '<option value="' . esc_attr( $value ) . '" ' . $selected_attr. '>' . esc_html( $label ) . '</option>';253 echo '<option value="' . esc_attr( $value ) . '" ' . esc_html($selected_attr) . '>' . esc_html( $label ) . '</option>'; 254 254 } 255 255 ?> … … 286 286 $selected_attr = selected($selected, $font_name, false); 287 287 ?> 288 <option value="<?php echo esc_attr($font_name); ?>" <?php echo $selected_attr; ?>><?php echo esc_html($font_name); ?></option>288 <option value="<?php echo esc_attr($font_name); ?>" <?php echo esc_html($selected_attr); ?>><?php echo esc_html($font_name); ?></option> 289 289 <?php 290 290 } … … 309 309 $value = isset( $this->settings['footer_description'] ) ? esc_textarea( $this->settings['footer_description'] ) : ''; 310 310 ?> 311 <textarea rows="5" cols="35" id="footer_description" name="hippoo_invoice_settings[footer_description]"><?php echo $value; ?></textarea>311 <textarea rows="5" cols="35" id="footer_description" name="hippoo_invoice_settings[footer_description]"><?php echo esc_html($value); ?></textarea> 312 312 <?php 313 313 } … … 332 332 <img id="courier_logo" src="<?php echo esc_url( $image_url ); ?>" width="64" height="64" /> 333 333 <div class="upload_buttons"> 334 <button id="courier_logo_upload_button" class="button upload"><?php _e( 'Upload Logo', 'hippoo-invoice' ); ?></button>335 <button id="courier_logo_clear_button" class="button remove"><?php _e( 'Remove', 'hippoo-invoice' ); ?></button>334 <button id="courier_logo_upload_button" class="button upload"><?php esc_html_e( 'Upload Logo', 'hippoo' ); ?></button> 335 <button id="courier_logo_clear_button" class="button remove"><?php esc_html_e( 'Remove', 'hippoo' ); ?></button> 336 336 </div> 337 337 </div> … … 352 352 ?> 353 353 <div class="notice notice-info is-dismissible"> 354 <p><?php _e( 'Setting saved.', 'hippoo-invoice' ); ?></p>354 <p><?php esc_html_e( 'Setting saved.', 'hippoo' ); ?></p> 355 355 </div> 356 356 <?php … … 358 358 359 359 public function handle_dismiss() { 360 if ( ! isset( $_REQUEST['dismiss_admin_notice_nonce'] ) || ! wp_verify_nonce( $_REQUEST['dismiss_admin_notice_nonce'], 'dismiss_admin_notice_nonce' ) ) { 360 $nonce = ( isset( $_REQUEST['dismiss_admin_notice_nonce'] ) ) ? sanitize_key( $_REQUEST['dismiss_admin_notice_nonce'] ) : ''; 361 362 if ( ! wp_verify_nonce( $nonce, 'dismiss_admin_notice_nonce' ) ) { 361 363 wp_send_json_error( array( 'message' => 'Nonce verification failed.' ) ); 362 364 } -
hippoo/trunk/invoice/templates/simple/factor.php
r3117864 r3249938 1 < html>1 <?php // phpcs:disable PluginCheck.CodeAnalysis.ImageFunctions.NonEnqueuedImage ?><html> 2 2 <head> 3 <title><?php esc_html_e( 'Invoice', 'hippoo -invoice' ); ?> <?php echo esc_html( $order->get_id() ); ?></title>3 <title><?php esc_html_e( 'Invoice', 'hippoo' ); ?> <?php echo esc_html( $order->get_id() ); ?></title> 4 4 <meta charset="utf-8"> 5 5 <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/> … … 139 139 <td class="shop-logo text-left"> 140 140 <?php if ( isset( $settings['invoice_show_logo'] ) && ! empty( $shop_logo ) ) : ?> 141 <img src="data:image/jpeg;base64,<?php echo esc_attr( $shop_logo ); ?>" width="48" alt="<?php esc_attr_e( 'Shop Logo', 'hippoo -invoice' ); ?>">141 <img src="data:image/jpeg;base64,<?php echo esc_attr( $shop_logo ); ?>" width="48" alt="<?php esc_attr_e( 'Shop Logo', 'hippoo' ); ?>"> 142 142 <?php endif; ?> 143 143 </td> … … 147 147 </td> 148 148 <td class="invoice-info"> 149 <div class="invoice-id"><?php esc_html_e( 'Invoice', 'hippoo -invoice' ); ?> <?php echo esc_html( $order->get_id() ); ?></div>149 <div class="invoice-id"><?php esc_html_e( 'Invoice', 'hippoo' ); ?> <?php echo esc_html( $order->get_id() ); ?></div> 150 150 <div class="invoice-barcode"> 151 <img src="data:image/jpeg;base64,<?php echo esc_attr( $invoice_barcode ); ?>" alt="<?php esc_attr_e( 'Invoice Barcode', 'hippoo -invoice' ); ?>">151 <img src="data:image/jpeg;base64,<?php echo esc_attr( $invoice_barcode ); ?>" alt="<?php esc_attr_e( 'Invoice Barcode', 'hippoo' ); ?>"> 152 152 </div> 153 153 </td> … … 163 163 <thead> 164 164 <tr> 165 <th class="text-left bill"><?php esc_html_e( 'Bill to:', 'hippoo -invoice' ); ?></th>165 <th class="text-left bill"><?php esc_html_e( 'Bill to:', 'hippoo' ); ?></th> 166 166 <?php if ( isset( $settings['show_customer_note'] ) && $settings['show_customer_note'] && $customer_note ) : ?> 167 <th class="text-left"><?php esc_html_e( 'Customer note:', 'hippoo -invoice' ); ?></th>167 <th class="text-left"><?php esc_html_e( 'Customer note:', 'hippoo' ); ?></th> 168 168 <?php endif; ?> 169 169 </tr> … … 181 181 <thead> 182 182 <tr> 183 <th class="text-left"><?php esc_html_e( 'Item', 'hippoo -invoice' ); ?></th>183 <th class="text-left"><?php esc_html_e( 'Item', 'hippoo' ); ?></th> 184 184 <?php if ( isset( $settings['show_product_sku_invoice'] ) && $settings['show_product_sku_invoice'] && ! empty( $sku ) ) : ?> 185 <th class="text-center"><?php esc_html_e( 'SKU', 'hippoo -invoice' ); ?></th>186 <?php endif; ?> 187 <th class="text-center"><?php esc_html_e( 'Qty', 'hippoo -invoice' ); ?></th>188 <th class="text-center"><?php esc_html_e( 'Price', 'hippoo -invoice' ); ?></th>189 <th class="text-right"><?php esc_html_e( 'Amount', 'hippoo -invoice' ); ?></th>185 <th class="text-center"><?php esc_html_e( 'SKU', 'hippoo' ); ?></th> 186 <?php endif; ?> 187 <th class="text-center"><?php esc_html_e( 'Qty', 'hippoo' ); ?></th> 188 <th class="text-center"><?php esc_html_e( 'Price', 'hippoo' ); ?></th> 189 <th class="text-right"><?php esc_html_e( 'Amount', 'hippoo' ); ?></th> 190 190 </tr> 191 191 </thead> … … 201 201 <?php if ( isset( $settings['show_product_sku_invoice'] ) && $settings['show_product_sku_invoice'] && ! empty( $sku ) ) : ?> 202 202 <td class="text-center"> 203 <img src="data:image/jpeg;base64,<?php echo esc_attr( base64_encode( generate_barcode_image( $product->get_sku() ) ) ); ?>" alt="<?php esc_attr_e( 'Product SKU Barcode', 'hippoo -invoice' ); ?>">203 <img src="data:image/jpeg;base64,<?php echo esc_attr( base64_encode( generate_barcode_image( $product->get_sku() ) ) ); ?>" alt="<?php esc_attr_e( 'Product SKU Barcode', 'hippoo' ); ?>"> 204 204 <div class="sku"><?php echo esc_html( $product->get_sku() ); ?></div> 205 205 </td> … … 214 214 <tr class="subtotal-row"> 215 215 <td colspan="2"></td> 216 <td colspan="1" class="text-right"><?php esc_html_e( 'Subtotal', 'hippoo -invoice' ); ?></td>216 <td colspan="1" class="text-right"><?php esc_html_e( 'Subtotal', 'hippoo' ); ?></td> 217 217 <td colspan="<?php echo ( isset( $settings['show_product_sku_invoice'] ) && $settings['show_product_sku_invoice'] ) ? 2 : 1; ?>" class="text-right"><?php echo esc_html( $order->get_subtotal() ); ?> <?php echo esc_html( $order->get_currency() ); ?></td> 218 218 </tr> … … 220 220 <tr class="discount-row"> 221 221 <td colspan="2"></td> 222 <td colspan="1" class="text-right"><?php esc_html_e( 'Discount', 'hippoo -invoice' ); ?></td>222 <td colspan="1" class="text-right"><?php esc_html_e( 'Discount', 'hippoo' ); ?></td> 223 223 <td colspan="<?php echo ( isset( $settings['show_product_sku_invoice'] ) && $settings['show_product_sku_invoice'] ) ? 2 : 1; ?>" class="text-right">-<?php echo esc_html( $order->get_total_discount() ); ?> <?php echo esc_html( $order->get_currency() ); ?></td> 224 224 </tr> … … 227 227 <tr class="tax-row"> 228 228 <td colspan="2"></td> 229 <td colspan="1" class="text-right"><?php esc_html_e( 'Tax', 'hippoo -invoice' ); ?></td>229 <td colspan="1" class="text-right"><?php esc_html_e( 'Tax', 'hippoo' ); ?></td> 230 230 <td colspan="<?php echo ( isset( $settings['show_product_sku_invoice'] ) && $settings['show_product_sku_invoice'] ) ? 2 : 1; ?>" class="text-right">+<?php echo esc_html( $order->get_total_tax() ); ?> <?php echo esc_html( $order->get_currency() ); ?></td> 231 231 </tr> … … 233 233 <tr class="total-row"> 234 234 <td colspan="2"></td> 235 <td colspan="1" class="text-right"><?php esc_html_e( 'Total', 'hippoo -invoice' ); ?></td>235 <td colspan="1" class="text-right"><?php esc_html_e( 'Total', 'hippoo' ); ?></td> 236 236 <td colspan="<?php echo ( isset( $settings['show_product_sku_invoice'] ) && $settings['show_product_sku_invoice'] ) ? 2 : 1; ?>" class="text-right"><?php echo esc_html( $order->get_total() ); ?> <?php echo esc_html( $order->get_currency() ); ?></td> 237 237 </tr> -
hippoo/trunk/invoice/templates/simple/label.php
r3117864 r3249938 1 < html>1 <?php // phpcs:disable PluginCheck.CodeAnalysis.ImageFunctions.NonEnqueuedImage ?><html> 2 2 <head> 3 <title><?php esc_html_e( 'Label', 'hippoo -invoice' ); ?></title>3 <title><?php esc_html_e( 'Label', 'hippoo' ); ?></title> 4 4 <meta charset="utf-8"> 5 5 <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/> … … 71 71 <tr> 72 72 <td class="shop-info"> 73 <h4 class="text-left"><?php esc_html_e( 'From:', 'hippoo -invoice' ); ?></h4><br>73 <h4 class="text-left"><?php esc_html_e( 'From:', 'hippoo' ); ?></h4><br> 74 74 <div class="address"><?php echo wp_kses_post( $shop_address ); ?></div> 75 75 </td> 76 76 <td class="invoice-logo text-right"> 77 77 <?php if ( isset( $settings['shipping_show_logo'] ) && ! empty( $shop_logo ) ) : ?> 78 <img src="data:image/jpeg;base64,<?php echo esc_attr( $shop_logo ); ?>" width="48" alt="<?php esc_attr_e( 'Shop Logo', 'hippoo -invoice' ); ?>">78 <img src="data:image/jpeg;base64,<?php echo esc_attr( $shop_logo ); ?>" width="48" alt="<?php esc_attr_e( 'Shop Logo', 'hippoo' ); ?>"> 79 79 <?php endif; ?> 80 80 </td> … … 82 82 <tr> 83 83 <td colspan="2"> 84 <h4 class="text-left"><?php esc_html_e( 'Ship to:', 'hippoo -invoice' ); ?></h4><br>84 <h4 class="text-left"><?php esc_html_e( 'Ship to:', 'hippoo' ); ?></h4><br> 85 85 <div class="address"> 86 86 <?php echo esc_html( $order->get_formatted_shipping_full_name() ); ?><br> … … 92 92 <tr> 93 93 <td colspan="2" class="additional"> 94 <h4><?php esc_html_e( 'Weight:', 'hippoo -invoice' ); ?> <?php echo esc_html( $weight ); ?> <?php echo esc_html( get_option( 'woocommerce_weight_unit' ) ); ?></h4>94 <h4><?php esc_html_e( 'Weight:', 'hippoo' ); ?> <?php echo esc_html( $weight ); ?> <?php echo esc_html( get_option( 'woocommerce_weight_unit' ) ); ?></h4> 95 95 </td> 96 96 </tr> … … 98 98 <tr class="no-border"> 99 99 <td colspan="2" class="text-center"> 100 <h4><?php esc_html_e( 'Invoice', 'hippoo -invoice' ); ?> <?php echo esc_html( $order->get_id() ); ?></h4><br>100 <h4><?php esc_html_e( 'Invoice', 'hippoo' ); ?> <?php echo esc_html( $order->get_id() ); ?></h4><br> 101 101 <div class="invoice-barcode"> 102 <img src="data:image/jpeg;base64,<?php echo esc_attr( $invoice_barcode ); ?>" alt="<?php esc_attr_e( 'Invoice Barcode', 'hippoo -invoice' ); ?>">102 <img src="data:image/jpeg;base64,<?php echo esc_attr( $invoice_barcode ); ?>" alt="<?php esc_attr_e( 'Invoice Barcode', 'hippoo' ); ?>"> 103 103 <br><br><br> 104 104 <?php if ( $settings['shipping_courier_logo'] ) : ?> 105 <img class="courier_logo" src="data:image/jpeg;base64,<?php echo esc_attr( $shipping_courier_logo ); ?>" alt="<?php esc_attr_e( 'Courier Logo', 'hippoo -invoice' ); ?>">105 <img class="courier_logo" src="data:image/jpeg;base64,<?php echo esc_attr( $shipping_courier_logo ); ?>" alt="<?php esc_attr_e( 'Courier Logo', 'hippoo' ); ?>"> 106 106 <?php endif; ?> 107 107 </div> -
hippoo/trunk/invoice/web_api_auth.php
r3117864 r3249938 104 104 $html_doc = generate_html( $order_id, 'factor' ); 105 105 header( 'Content-Type: text/html; charset=utf-8' ); 106 echo $html_doc; 106 echo $html_doc; // phpcs:ignore 107 107 exit; 108 108 } … … 112 112 $html_doc = generate_html( $order_id, 'label' ); 113 113 header( 'Content-Type: text/html; charset=utf-8' ); 114 echo $html_doc; 114 echo $html_doc; // phpcs:ignore 115 115 exit; 116 116 } 117 117 } 118 ?> -
hippoo/trunk/invoice/woocommerce/my-account.php
r3117864 r3249938 1 <?php 1 <?php // phpcs:disable PluginCheck.CodeAnalysis.ImageFunctions.NonEnqueuedImage 2 2 3 3 class Hippoo_Ticket_Woo_My_Account { … … 10 10 11 11 function enqueue_scripts() { 12 wp_enqueue_style( 'hippoo-css', HIPPOO_INVOICE_PLUGIN_URL . 'assets/css/style.css' );13 wp_enqueue_script( 'hippoo-js', HIPPOO_INVOICE_PLUGIN_URL . 'assets/js/script.js', array( 'jquery' ), null, true ); // Enqueue script with dependencies12 wp_enqueue_style( 'hippoo-css', HIPPOO_INVOICE_PLUGIN_URL . 'assets/css/style.css', [], hippoo_version ); 13 wp_enqueue_script( 'hippoo-js', HIPPOO_INVOICE_PLUGIN_URL . 'assets/js/script.js', array( 'jquery' ), hippoo_version, true ); // Enqueue script with dependencies 14 14 } 15 15 … … 48 48 $order_id = $order->get_id(); 49 49 50 echo '<a href="?post_id=' . $order_id . '&download_type=factor" target="_blank" class="factor-download"><img src="' . HIPPOO_INVOICE_PLUGIN_URL . 'assets/images/invoice-factor.svg" /></a>';50 echo '<a href="?post_id=' . intval($order_id) . '&download_type=factor" target="_blank" class="factor-download"><img src="' . esc_url(HIPPOO_INVOICE_PLUGIN_URL . 'assets/images/invoice-factor.svg') . '" /></a>'; 51 51 } 52 52 } -
hippoo/trunk/invoice/woocommerce/order-test.php
r3117864 r3249938 46 46 add_meta_box( 47 47 'address_validation_actions', 48 __( 'Validate Address', ' textdomain' ),48 __( 'Validate Address', 'hippoo' ), 49 49 array( $this, 'render_address_validation_actions' ), 50 50 $screen, -
hippoo/trunk/invoice/woocommerce/order.php
r3117864 r3249938 1 <?php 1 <?php // phpcs:disable PluginCheck.CodeAnalysis.ImageFunctions.NonEnqueuedImage 2 2 3 3 ## Add Colums to orders table … … 47 47 case 'order_id_barcode': 48 48 $barcode = base64_encode( generate_barcode_html( $order_id ) ); 49 echo '<img src="' . HIPPOO_INVOICE_PLUGIN_URL . 'assets/images/barcode-scanner.svg" data-src="' . $barcode . '" data-text="' . $order_id. '" class="hippoo-tooltip" />';49 echo '<img src="' . esc_url(HIPPOO_INVOICE_PLUGIN_URL . 'assets/images/barcode-scanner.svg') . '" data-src="' . esc_attr($barcode) . '" data-text="' . esc_attr($order_id) . '" class="hippoo-tooltip" />'; 50 50 break; 51 51 52 52 case 'order_print': 53 echo '<a href="?post_id=' . $order_id. '&download_type=factor" target="_blank" data-barcode="' .54 $order_id. '" data-type="factor" data-text="Invoice" class="hippoo-tooltip" title="Invoice"><img src="' .55 HIPPOO_INVOICE_PLUGIN_URL . 'assets/images/invoice-factor.svg" /></a>';53 echo '<a href="?post_id=' . intval($order_id) . '&download_type=factor" target="_blank" data-barcode="' . 54 esc_attr($order_id) . '" data-type="factor" data-text="Invoice" class="hippoo-tooltip" title="Invoice"><img src="' . 55 esc_url(HIPPOO_INVOICE_PLUGIN_URL . 'assets/images/invoice-factor.svg') . '" /></a>'; 56 56 57 echo '<a href="?post_id=' . $order_id. '&download_type=label" target="_blank" data-barcode="' .58 $order_id. '" data-type="label" data-text="Shipping Label" class="hippoo-tooltip" title="Shipping Label"><img src="' .59 HIPPOO_INVOICE_PLUGIN_URL . 'assets/images/shipping-label.svg" /></a>';57 echo '<a href="?post_id=' . intval($order_id) . '&download_type=label" target="_blank" data-barcode="' . 58 esc_attr($order_id) . '" data-type="label" data-text="Shipping Label" class="hippoo-tooltip" title="Shipping Label"><img src="' . 59 esc_url(HIPPOO_INVOICE_PLUGIN_URL . 'assets/images/shipping-label.svg') . '" /></a>'; 60 60 break; 61 61 } … … 70 70 71 71 function add_stock_status_header() { 72 echo '<th class="quantity sortable" data-sort="string-ins">' . __('Barcode', 'hippoo-invoice') . '</th>';72 echo '<th class="quantity sortable" data-sort="string-ins">' . esc_html__('Barcode', 'hippoo') . '</th>'; 73 73 } 74 74 … … 82 82 $barcode = base64_encode(generate_barcode_html($sku)); 83 83 84 echo '<td class="barcode" width="1%"><img src="' . HIPPOO_INVOICE_PLUGIN_URL . 'assets/images/barcode-scanner.svg" data-src="' . $barcode . '" data-text="' . $sku. '" class="hippoo-tooltip" /></td>';84 echo '<td class="barcode" width="1%"><img src="' . esc_url(HIPPOO_INVOICE_PLUGIN_URL . 'assets/images/barcode-scanner.svg') . '" data-src="' . esc_attr($barcode) . '" data-text="' . esc_attr($sku) . '" class="hippoo-tooltip" /></td>'; 85 85 } 86 86 … … 213 213 add_meta_box( 214 214 'hippoo_invoice_order_barcode_metabox', 215 __('Order ID Barcode', 'hippoo -invoice'),215 __('Order ID Barcode', 'hippoo'), 216 216 'display_order_barcode_metabox', 217 217 $post_type, -
hippoo/trunk/invoice/woocommerce/product.php
r3117864 r3249938 1 <?php 1 <?php // phpcs:disable PluginCheck.CodeAnalysis.ImageFunctions.NonEnqueuedImage 2 2 3 3 class Hippoo_Ticket_Woo_Product { … … 40 40 $barcode = base64_encode(generate_barcode_html($sku)); 41 41 42 echo '<img src="' . HIPPOO_INVOICE_PLUGIN_URL . 'assets/images/barcode-scanner.svg" data-src="' . $barcode . '" data-text="' . $sku. '" class="hippoo-tooltip" />';42 echo '<img src="' . esc_url(HIPPOO_INVOICE_PLUGIN_URL . 'assets/images/barcode-scanner.svg') . '" data-src="' . esc_attr($barcode) . '" data-text="' . esc_attr($sku) . '" class="hippoo-tooltip" />'; 43 43 } 44 44 } … … 64 64 $barcode = generate_barcode_html( $sku ); 65 65 66 echo $barcode . '<br><strong>' . $sku. '</strong>';66 echo esc_html($barcode) . '<br><strong>' . esc_html($sku) . '</strong>'; 67 67 } 68 68 } -
hippoo/trunk/readme.txt
r3237006 r3249938 1 === Hippoo mobile app for woocommerce ===1 === Hippoo Mobile App for WooCommerce === 2 2 Contributors: Hippooo 3 3 Donate link: https://Hippoo.app/ … … 15 15 == Description == 16 16 <h3><b>Hippoo WooCommerce App | Your Store, Anywhere, Anytime</b></h3> 17 <span style="font-weight: 400;">The <strong><a href="https://hippoo.app">Hippoo WooCommerce app</a> </strong> is a powerful extension that enhances the functionality of your WooCommerce shop. Seamlessly integrate your shop with the Hippoo Android appto unlock advanced features, including the creation of out-of-stock lists, adding images to order products via API, and user authentication for optimal app utilization. Take control of your shop's inventory, order fulfillment, and customer engagement with ease.</span>17 <span style="font-weight: 400;">The <strong><a href="https://hippoo.app">Hippoo WooCommerce app</a> </strong> is a powerful extension that enhances the functionality of your WooCommerce shop. Seamlessly integrate your shop with the Hippoo mobile app (both Android and iOS) to unlock advanced features, including the creation of out-of-stock lists, adding images to order products via API, and user authentication for optimal app utilization. Take control of your shop's inventory, order fulfillment, and customer engagement with ease.</span> 18 18 <h3><b>Key Features:</b></h3> 19 19 <ol> … … 33 33 </ol> 34 34 35 <h3><b>Progressive Web App (PWA) Support</b></h3> 36 <span style="font-weight: 400;">Hippoo WooCommerce now enables a <b>PWA for your store</b>, allowing customers to install it on their devices. By default, a "Designed by Hippoo WooCommerce app" credit appears under the PWA. The entire PWA feature can be disabled in the settings.</span> 37 38 <h3><b>Why Use Hippoo PWA for Instagram Shop?</b></h3> 39 <span style="font-weight: 400;">The PWA is <b>perfect for Instagram Shop</b> because of its <b>simple design, mobile-friendly interface, and fast performance</b>. It uses the <b>WooCommerce Store API</b>, ensuring <b>quick loading times and a smooth shopping experience</b> for customers.</span> 40 41 42 35 43 <h3><b>To install the Hippoo WooCommerce app on your phone:</b></h3> 36 44 <ol> 37 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">Visit the Google Play Store using the following link:</span><a href="https://play.google.com/store/apps/details?id=io.hippo"> <span style="font-weight: 400;">Hippoo Android App</span></a><span style="font-weight: 400;">.</span></li> 38 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">Click on the "Install" button to download and install the Hippoo app on your Android device.</span></li> 45 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">For Android users: Visit the Google Play Store using the following link:</span><a href="https://play.google.com/store/apps/details?id=io.hippo"> <span style="font-weight: 400;">Hippoo Android App</span></a><span style="font-weight: 400;">.</span></li> 46 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">For iPhone users: Visit the App Store using the following link:</span> <a href="https://apps.apple.com/ee/app/hippoo-woocommerce-admin-app/id1667265325" style="font-weight: 400;">Hippoo iOS App</a>.</li> 47 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">Click on the "Install" button to download and install the Hippoo app on your mobile device.</span></li> 39 48 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">Open the Hippoo app and follow the on-screen instructions to authenticate your shop and start utilizing the advanced features.</span></li> 40 49 </ol> … … 44 53 1. Upload the plugin folder to the `/wp-content/plugins/` directory 45 54 2. Activate the plugin through the 'Plugins' menu in WordPress 46 3. Install <a href="https://play.google.com/store/apps/details?id=io.hippo">Hippo WooCommerce app (Android)</a> or <a href="https://apps.apple.com/ee/app/hippoo-woocommerce-admin-app/id1667265325">Hippoo WooCommerce app for iOS</a>55 3. Install <a href="https://play.google.com/store/apps/details?id=io.hippo">Hippoo WooCommerce app for Android</a> or <a href="https://apps.apple.com/ee/app/hippoo-woocommerce-admin-app/id1667265325">Hippoo WooCommerce app for iOS</a>. 47 56 48 57 == Screenshots == … … 57 66 58 67 == Changelog == 59 68 * 1.5.8 - Minor Improvements. 69 * 1.5.1 - Added PWA feature with optional store activation. 60 70 * 1.5.0 - Improvements & Enhancements Enhanced app functionality for a smoother user experience. Improved plugin authentication system, allowing seamless integration with third-party plugins. Optimized performance and security for better reliability. 61 71 * 1.4.3 - Updated the mobile notification text and title, Round the weight on orders
Note: See TracChangeset
for help on using the changeset viewer.