@@ -1,4 +1,4 @@ |
||
1 | -<?php if ( !defined( 'ABSPATH' ) ) exit; |
|
1 | +<?php if (!defined('ABSPATH')) exit; |
|
2 | 2 | /** |
3 | 3 | * Plugin database options |
4 | 4 | * |
@@ -1,4 +1,6 @@ |
||
1 | -<?php if ( !defined( 'ABSPATH' ) ) exit; |
|
1 | +<?php if ( !defined( 'ABSPATH' ) ) { |
|
2 | + exit; |
|
3 | +} |
|
2 | 4 | /** |
3 | 5 | * Fichier de définition du modèle des taxinomies / File for term model definition |
4 | 6 | * |
@@ -1,4 +1,4 @@ |
||
1 | -<?php if ( !defined( 'ABSPATH' ) ) exit; |
|
1 | +<?php if (!defined('ABSPATH')) exit; |
|
2 | 2 | /** |
3 | 3 | * Plugin database options |
4 | 4 | * |
@@ -1,4 +1,6 @@ |
||
1 | -<?php if ( !defined( 'ABSPATH' ) ) exit; |
|
1 | +<?php if ( !defined( 'ABSPATH' ) ) { |
|
2 | + exit; |
|
3 | +} |
|
2 | 4 | /** |
3 | 5 | * Fichier de définition du modèle des taxinomies / File for term model definition |
4 | 6 | * |
@@ -1,4 +1,6 @@ |
||
1 | -<?php if ( !defined( 'ABSPATH' ) ) exit; |
|
1 | +<?php if ( !defined( 'ABSPATH' ) ) { |
|
2 | + exit; |
|
3 | +} |
|
2 | 4 | /** |
3 | 5 | * Fichier de définition du modèle des taxinomies / File for term model definition |
4 | 6 | * |
@@ -1,24 +1,24 @@ discard block |
||
1 | -<?php if ( !defined( 'ABSPATH' ) ) exit; |
|
1 | +<?php if (!defined('ABSPATH')) exit; |
|
2 | 2 | ?> |
3 | -<p><?php _e( 'Number of inconsistent product : ', 'wps_product' ); echo $inconsistent_product_number; ?></p> |
|
3 | +<p><?php _e('Number of inconsistent product : ', 'wps_product'); echo $inconsistent_product_number; ?></p> |
|
4 | 4 | |
5 | 5 | |
6 | 6 | <form class="wps-product-check-data-form" action="<?php echo admin_url('admin-ajax.php'); ?>" method="post"> |
7 | - <?php wp_nonce_field( 'ajax_save_product_price' ); ?> |
|
7 | + <?php wp_nonce_field('ajax_save_product_price'); ?> |
|
8 | 8 | <table> |
9 | 9 | <tr> |
10 | 10 | <th>ID</th> |
11 | - <th><?php _e( 'Product name', 'wps_product' ); ?></th> |
|
12 | - <th><?php _e( 'Attribute price', 'wps_product' ); ?></th> |
|
13 | - <th><?php _e( 'Meta : _product_price', 'wps_product' ); ?></th> |
|
14 | - <th><?php _e( 'Meta : _wps_price_infos', 'wps_product' ); ?></th> |
|
15 | - <th><?php _e( 'Meta : _wpshop_displayed_price', 'wps_product' ); ?></th> |
|
16 | - <th><?php _e( 'Meta : _wpshop_product_metadata', 'wps_product' ); ?></th> |
|
17 | - <th><?php _e( 'Fix the value', 'wps_product' ); ?></th> |
|
11 | + <th><?php _e('Product name', 'wps_product'); ?></th> |
|
12 | + <th><?php _e('Attribute price', 'wps_product'); ?></th> |
|
13 | + <th><?php _e('Meta : _product_price', 'wps_product'); ?></th> |
|
14 | + <th><?php _e('Meta : _wps_price_infos', 'wps_product'); ?></th> |
|
15 | + <th><?php _e('Meta : _wpshop_displayed_price', 'wps_product'); ?></th> |
|
16 | + <th><?php _e('Meta : _wpshop_product_metadata', 'wps_product'); ?></th> |
|
17 | + <th><?php _e('Fix the value', 'wps_product'); ?></th> |
|
18 | 18 | </tr> |
19 | 19 | <?php |
20 | - if( !empty( $list_product ) ): |
|
21 | - foreach( $list_product as $product ): |
|
20 | + if (!empty($list_product)): |
|
21 | + foreach ($list_product as $product): |
|
22 | 22 | ?> |
23 | 23 | <tr> |
24 | 24 | <td><?php echo $product->ID; ?></td> |
@@ -35,5 +35,5 @@ discard block |
||
35 | 35 | ?> |
36 | 36 | </table> |
37 | 37 | |
38 | - <input class="button-primary wps-product-submit-form" name="Submit" type="submit" value="<?php _e( 'Save changes', 'wps_product'); ?>" /> |
|
38 | + <input class="button-primary wps-product-submit-form" name="Submit" type="submit" value="<?php _e('Save changes', 'wps_product'); ?>" /> |
|
39 | 39 | </form> |
@@ -1,4 +1,6 @@ |
||
1 | -<?php if ( !defined( 'ABSPATH' ) ) exit; |
|
1 | +<?php if ( !defined( 'ABSPATH' ) ) { |
|
2 | + exit; |
|
3 | +} |
|
2 | 4 | /** |
3 | 5 | * Fichier de définition du modèle des taxinomies / File for term model definition |
4 | 6 | * |
@@ -1,14 +1,14 @@ discard block |
||
1 | -<?php if ( !defined( 'ABSPATH' ) ) exit; |
|
1 | +<?php if (!defined('ABSPATH')) exit; |
|
2 | 2 | ?> |
3 | -<form id="wps_product_quick_add_form" method="post" action="<?php echo admin_url( 'admin-ajax.php' ); ?>" > |
|
3 | +<form id="wps_product_quick_add_form" method="post" action="<?php echo admin_url('admin-ajax.php'); ?>" > |
|
4 | 4 | <input type="hidden" name="action" value="wps-product-quick-add"> |
5 | - <?php wp_nonce_field( 'create_product' ); ?> |
|
5 | + <?php wp_nonce_field('create_product'); ?> |
|
6 | 6 | <div class="wps-boxed" style="margin-top:10px;" > |
7 | - <span class="wps-h5"><?php _e( 'Product', 'wpshop'); ?></span> |
|
7 | + <span class="wps-h5"><?php _e('Product', 'wpshop'); ?></span> |
|
8 | 8 | |
9 | 9 | <div class="wpshop_cls" > |
10 | 10 | <div class="wpshop_form_label _product_title_label alignleft" > |
11 | - <label for="attribute_product_title" ><?php _e( 'Product name', 'wpshop'); ?> <span class="wpshop_required" >*</span></label> |
|
11 | + <label for="attribute_product_title" ><?php _e('Product name', 'wpshop'); ?> <span class="wpshop_required" >*</span></label> |
|
12 | 12 | </div> |
13 | 13 | <div class="wpshop_form_input_element _product_title_input alignleft" > |
14 | 14 | <input type="text" name="post_title" id="post_title" value="" class="wpshop_product_attribute_post_title wpshop_attributes_display" required > |
@@ -17,7 +17,7 @@ discard block |
||
17 | 17 | |
18 | 18 | <div class="wpshop_cls" > |
19 | 19 | <div class="wpshop_form_label _description_label alignleft" > |
20 | - <label for="attribute_description" ><?php _e( 'Description', 'wpshop'); ?></label> |
|
20 | + <label for="attribute_description" ><?php _e('Description', 'wpshop'); ?></label> |
|
21 | 21 | </div> |
22 | 22 | <div class="wpshop_form_input_element _description_input alignleft" > |
23 | 23 | <textarea name="post_content" id="post_content" class="wpshop_product_post_content wpshop_attributes_display" rows="2"></textarea> |
@@ -27,35 +27,35 @@ discard block |
||
27 | 27 | |
28 | 28 | <?php |
29 | 29 | /** Get the attribute set list */ |
30 | - $attribute_set_list = wpshop_attributes_set::get_attribute_set_list_for_entity( wpshop_entities::get_entity_identifier_from_code( 'wpshop_product' ) ); |
|
30 | + $attribute_set_list = wpshop_attributes_set::get_attribute_set_list_for_entity(wpshop_entities::get_entity_identifier_from_code('wpshop_product')); |
|
31 | 31 | $default_set = 0; |
32 | - if ( 1 == count( $attribute_set_list ) ) { |
|
33 | - $default_set = $attribute_set_list[ 0 ]->id; |
|
32 | + if (1 == count($attribute_set_list)) { |
|
33 | + $default_set = $attribute_set_list[0]->id; |
|
34 | 34 | } |
35 | 35 | ?> |
36 | 36 | <?php /** Check if attribute set list is not empty in order to display a dropdown for sélection */ ?> |
37 | - <?php if ( !empty( $attribute_set_list ) && ( 1 < count( $attribute_set_list ) ) ) : ?> |
|
37 | + <?php if (!empty($attribute_set_list) && (1 < count($attribute_set_list))) : ?> |
|
38 | 38 | <div style=" width:80%; margin: 0 auto 10px auto; " > |
39 | - <?php _e( 'Product type to create', 'wpshop' ); ?> : |
|
40 | - <select name="wps-product-attribute-set" data-nonce="<?php echo wp_create_nonce( 'attribute_list_reload' ); ?>" > |
|
41 | - <?php foreach( $attribute_set_list as $attribute_set ) : ?> |
|
39 | + <?php _e('Product type to create', 'wpshop'); ?> : |
|
40 | + <select name="wps-product-attribute-set" data-nonce="<?php echo wp_create_nonce('attribute_list_reload'); ?>" > |
|
41 | + <?php foreach ($attribute_set_list as $attribute_set) : ?> |
|
42 | 42 | <?php $is_default_set = false; ?> |
43 | - <?php if ( !empty( $attribute_set->default_set ) && strtolower( __( 'Yes', 'wpshop' ) ) == strtolower( __( $attribute_set->default_set, 'wpshop' ) ) ) : ?> |
|
43 | + <?php if (!empty($attribute_set->default_set) && strtolower(__('Yes', 'wpshop')) == strtolower(__($attribute_set->default_set, 'wpshop'))) : ?> |
|
44 | 44 | <?php $is_default_set = true; ?> |
45 | 45 | <?php $default_set = $attribute_set->id; ?> |
46 | 46 | <?php endif; ?> |
47 | - <option value="<?php echo $attribute_set->id; ?>" <?php selected( ( !empty( $chosen_set ) ? true : $is_default_set ) , true, true ); ?> ><?php echo $attribute_set->name; ?></option> |
|
47 | + <option value="<?php echo $attribute_set->id; ?>" <?php selected((!empty($chosen_set) ? true : $is_default_set), true, true); ?> ><?php echo $attribute_set->name; ?></option> |
|
48 | 48 | <?php endforeach; ?> |
49 | 49 | </select> |
50 | 50 | </div> |
51 | 51 | <?php endif; ?> |
52 | 52 | |
53 | 53 | <?php /** If default set or if there is a selected set get existing attributes list for this set */ ?> |
54 | - <?php if ( !empty( $default_set ) || !empty( $chosen_set ) ) : ?> |
|
55 | - <?php $this->display_attribute( !empty( $chosen_set ) ? $chosen_set : ( !empty( $default_set ) ? $default_set : 0 ) ); ?> |
|
54 | + <?php if (!empty($default_set) || !empty($chosen_set)) : ?> |
|
55 | + <?php $this->display_attribute(!empty($chosen_set) ? $chosen_set : (!empty($default_set) ? $default_set : 0)); ?> |
|
56 | 56 | <?php endif; ?> |
57 | 57 | |
58 | - <button class="wps-bton-first-mini-rounded alignRight" ><?php _e( 'Add product', 'wpshop'); ?></button> |
|
58 | + <button class="wps-bton-first-mini-rounded alignRight" ><?php _e('Add product', 'wpshop'); ?></button> |
|
59 | 59 | </form> |
60 | 60 | <script type="text/javascript" > |
61 | 61 | jQuery( document ).ready( function() { |
@@ -83,7 +83,7 @@ discard block |
||
83 | 83 | } |
84 | 84 | } |
85 | 85 | if ( has_error ) { |
86 | - alert( wpshopConvertAccentTojs( "<?php _e( 'Please fill all fields mark as required', 'wpshop' ); ?>" ) ); |
|
86 | + alert( wpshopConvertAccentTojs( "<?php _e('Please fill all fields mark as required', 'wpshop'); ?>" ) ); |
|
87 | 87 | return false; |
88 | 88 | } |
89 | 89 | }, |
@@ -1,4 +1,6 @@ |
||
1 | -<?php if ( !defined( 'ABSPATH' ) ) exit; |
|
1 | +<?php if ( !defined( 'ABSPATH' ) ) { |
|
2 | + exit; |
|
3 | +} |
|
2 | 4 | /** |
3 | 5 | * Fichier de définition du modèle des taxinomies / File for term model definition |
4 | 6 | * |
@@ -1,9 +1,9 @@ |
||
1 | -<?php if ( !defined( 'ABSPATH' ) ) exit; |
|
2 | - if( !empty($files) ) : ?> |
|
3 | -<u><strong><?php _e( 'Uploaded files', 'wpshop' ); ?> :</strong></u> |
|
1 | +<?php if (!defined('ABSPATH')) exit; |
|
2 | + if (!empty($files)) : ?> |
|
3 | +<u><strong><?php _e('Uploaded files', 'wpshop'); ?> :</strong></u> |
|
4 | 4 | <ul> |
5 | -<?php foreach( $files as $file ) : ?> |
|
6 | -<li><a href="<?php echo wp_get_attachment_url( $file->ID ); ?>" target="_blank"><?php echo $file->post_title; ?></a> <a href="#" data-nonce="<?php echo wp_create_nonce( 'wps_mass_delete_file' ); ?>" class="wps-mass-delete-file" id="wps-mass-delete-file-<?php echo $file->ID; ?>"><span class="wps-icon-trash"></span></a></li> |
|
5 | +<?php foreach ($files as $file) : ?> |
|
6 | +<li><a href="<?php echo wp_get_attachment_url($file->ID); ?>" target="_blank"><?php echo $file->post_title; ?></a> <a href="#" data-nonce="<?php echo wp_create_nonce('wps_mass_delete_file'); ?>" class="wps-mass-delete-file" id="wps-mass-delete-file-<?php echo $file->ID; ?>"><span class="wps-icon-trash"></span></a></li> |
|
7 | 7 | <?php endforeach; ?> |
8 | 8 | </ul> |
9 | 9 | <?php endif; ?> |
@@ -1,4 +1,6 @@ |
||
1 | -<?php if ( !defined( 'ABSPATH' ) ) exit; |
|
1 | +<?php if ( !defined( 'ABSPATH' ) ) { |
|
2 | + exit; |
|
3 | +} |
|
2 | 4 | /** |
3 | 5 | * Fichier de définition du modèle des taxinomies / File for term model definition |
4 | 6 | * |
@@ -1,7 +1,7 @@ |
||
1 | -<?php if ( !defined( 'ABSPATH' ) ) exit; |
|
1 | +<?php if (!defined('ABSPATH')) exit; |
|
2 | 2 | ?> |
3 | 3 | <div class="wps-table-content wps-table-row"> |
4 | - <div class="wps-table-cell wps-cart-item-img"><a href="<?php echo get_permalink($ordered_product); ?>"><?php echo get_the_post_thumbnail( $ordered_product, 'thumbnail', array( 'class' => 'wps-circlerounded') ); ?></a></div> |
|
5 | - <div class="wps-table-cell"><a href="<?php echo get_permalink($ordered_product); ?>" target="_blank"><?php echo get_the_title( $ordered_product ); ?></a></div> |
|
6 | - <div class="wps-table-cell"><button class="wps-bton-first-mini-rounded wps-add-opinion-opener" data-nonce="<?php echo wp_create_nonce( 'wps_fill_opinion_modal' ); ?>" id="wps-add-opinion-<?php echo $ordered_product; ?>"><?php _e( 'Add your opinion', 'wps_opinion'); ?></button></div> |
|
4 | + <div class="wps-table-cell wps-cart-item-img"><a href="<?php echo get_permalink($ordered_product); ?>"><?php echo get_the_post_thumbnail($ordered_product, 'thumbnail', array('class' => 'wps-circlerounded')); ?></a></div> |
|
5 | + <div class="wps-table-cell"><a href="<?php echo get_permalink($ordered_product); ?>" target="_blank"><?php echo get_the_title($ordered_product); ?></a></div> |
|
6 | + <div class="wps-table-cell"><button class="wps-bton-first-mini-rounded wps-add-opinion-opener" data-nonce="<?php echo wp_create_nonce('wps_fill_opinion_modal'); ?>" id="wps-add-opinion-<?php echo $ordered_product; ?>"><?php _e('Add your opinion', 'wps_opinion'); ?></button></div> |
|
7 | 7 | </div> |
@@ -1,4 +1,6 @@ |
||
1 | -<?php if ( !defined( 'ABSPATH' ) ) exit; |
|
1 | +<?php if ( !defined( 'ABSPATH' ) ) { |
|
2 | + exit; |
|
3 | +} |
|
2 | 4 | /** |
3 | 5 | * Fichier de définition du modèle des taxinomies / File for term model definition |
4 | 6 | * |
@@ -1,35 +1,35 @@ discard block |
||
1 | -<?php if ( !defined( 'ABSPATH' ) ) exit; |
|
1 | +<?php if (!defined('ABSPATH')) exit; |
|
2 | 2 | ?> |
3 | 3 | <div class="wps-opinion-error-container"></div> |
4 | -<form method="post" action="<?php echo admin_url( 'admin-ajax.php' ); ?>" id="wps-add-opinion-form"> |
|
4 | +<form method="post" action="<?php echo admin_url('admin-ajax.php'); ?>" id="wps-add-opinion-form"> |
|
5 | 5 | |
6 | 6 | <div class="wps-row wps-gridwrapper2-padded"> |
7 | 7 | |
8 | 8 | <div class="wps-form-group"> |
9 | 9 | <input type="hidden" name="action" value="wps-opinion-save-form"/> |
10 | - <?php wp_nonce_field( 'wps_opinion_save_form' ); ?> |
|
10 | + <?php wp_nonce_field('wps_opinion_save_form'); ?> |
|
11 | 11 | <input type="hidden" name="wps-opinion-product-id" value="<?php echo $pid; ?>"/> |
12 | - <label for="wps-opinion-comment"><?php _e( 'Your opinion', 'wps_opinion' ); ?></label> |
|
12 | + <label for="wps-opinion-comment"><?php _e('Your opinion', 'wps_opinion'); ?></label> |
|
13 | 13 | <div class="wps-form"><textarea id="wps-opinion-comment" name="wps-opinion-comment"></textarea></div> |
14 | 14 | </div> |
15 | 15 | <div class="wps-form-group"> |
16 | 16 | <div> |
17 | 17 | <input type="hidden" name="action" value="wps-opinion-save-form"/> |
18 | - <label for="wps-opinion-comment"><?php _e( 'Your rate', 'wps_opinion' ); ?></label> |
|
18 | + <label for="wps-opinion-comment"><?php _e('Your rate', 'wps_opinion'); ?></label> |
|
19 | 19 | <div class="wps-form"> |
20 | 20 | <select name="wps-opinion-rate" id="wps-opinion-rate" > |
21 | - <?php for( $i = 0; $i <= 5 ; $i++) { ?> |
|
21 | + <?php for ($i = 0; $i <= 5; $i++) { ?> |
|
22 | 22 | <option value="<?php echo $i; ?>" ><?php echo $i; ?></option> |
23 | 23 | <?php } ?> |
24 | 24 | </select> |
25 | 25 | </div> |
26 | 26 | </div> |
27 | 27 | <div> |
28 | - <label for="wps-opinion-stars"><?php _e( 'Star rate', 'wps_opinion' ); ?></label> |
|
29 | - <div class="wps-form" id="wps-opinion-star-container" data-nonce="<?php echo wp_create_nonce( 'wps_update_opinion_star_rate' ); ?>"> |
|
28 | + <label for="wps-opinion-stars"><?php _e('Star rate', 'wps_opinion'); ?></label> |
|
29 | + <div class="wps-form" id="wps-opinion-star-container" data-nonce="<?php echo wp_create_nonce('wps_update_opinion_star_rate'); ?>"> |
|
30 | 30 | <?php |
31 | 31 | $wps_opinion_ctr = new wps_opinion_ctr(); |
32 | - echo $wps_opinion_ctr->display_stars( 0 ); |
|
32 | + echo $wps_opinion_ctr->display_stars(0); |
|
33 | 33 | ?> |
34 | 34 | </div> |
35 | 35 | </div> |
@@ -39,5 +39,5 @@ discard block |
||
39 | 39 | |
40 | 40 | </form> |
41 | 41 | <div class="wps-form-group"> |
42 | - <button class="wps-bton-first-rounded" id="wps-save-opinion"><?php _e( 'Save your opinion', 'wps_opinion' ); ?></button> |
|
42 | + <button class="wps-bton-first-rounded" id="wps-save-opinion"><?php _e('Save your opinion', 'wps_opinion'); ?></button> |
|
43 | 43 | </div> |
@@ -1,4 +1,4 @@ |
||
1 | -<?php if ( !defined( 'ABSPATH' ) ) exit; |
|
1 | +<?php if (!defined('ABSPATH')) exit; |
|
2 | 2 | /** |
3 | 3 | * Plugin database options |
4 | 4 | * |
@@ -1,4 +1,6 @@ |
||
1 | -<?php if ( !defined( 'ABSPATH' ) ) exit; |
|
1 | +<?php if ( !defined( 'ABSPATH' ) ) { |
|
2 | + exit; |
|
3 | +} |
|
2 | 4 | /** |
3 | 5 | * Fichier de définition du modèle des taxinomies / File for term model definition |
4 | 6 | * |
@@ -1,4 +1,6 @@ |
||
1 | -<?php if ( !defined( 'ABSPATH' ) ) exit; |
|
1 | +<?php if ( !defined( 'ABSPATH' ) ) { |
|
2 | + exit; |
|
3 | +} |
|
2 | 4 | /** |
3 | 5 | * Fichier de définition du modèle des taxinomies / File for term model definition |
4 | 6 | * |
@@ -1,24 +1,24 @@ discard block |
||
1 | -<?php if ( !defined( 'ABSPATH' ) ) exit; |
|
1 | +<?php if (!defined('ABSPATH')) exit; |
|
2 | 2 | class wpshop_customer_search { |
3 | 3 | |
4 | 4 | function __construct() { |
5 | - if ( is_admin() ) { |
|
6 | - add_filter( 'posts_where', array(&$this, 'wpshop_search_where_in_customer'), 10, 2 ); |
|
5 | + if (is_admin()) { |
|
6 | + add_filter('posts_where', array(&$this, 'wpshop_search_where_in_customer'), 10, 2); |
|
7 | 7 | } |
8 | 8 | } |
9 | 9 | |
10 | - public function wpshop_search_where_in_customer( $where ) { |
|
11 | - $post_type = !empty( $_GET['post_type'] ) ? sanitize_text_field( $_GET['post_type'] ) : ''; |
|
12 | - $s = !empty( $_GET['s'] ) ? sanitize_text_field( $_GET['s'] ) : ''; |
|
13 | - $entity_filter = !empty( $_GET['filter'] ) ? sanitize_text_field( $_GET['filter'] ) : ''; |
|
10 | + public function wpshop_search_where_in_customer($where) { |
|
11 | + $post_type = !empty($_GET['post_type']) ? sanitize_text_field($_GET['post_type']) : ''; |
|
12 | + $s = !empty($_GET['s']) ? sanitize_text_field($_GET['s']) : ''; |
|
13 | + $entity_filter = !empty($_GET['filter']) ? sanitize_text_field($_GET['filter']) : ''; |
|
14 | 14 | |
15 | - if( is_admin() && ( !empty($post_type) && ( $post_type == WPSHOP_NEWTYPE_IDENTIFIER_CUSTOMERS ) ) && ( !empty( $s ) || !empty( $entity_filter ) ) ) { |
|
15 | + if (is_admin() && (!empty($post_type) && ($post_type == WPSHOP_NEWTYPE_IDENTIFIER_CUSTOMERS)) && (!empty($s) || !empty($entity_filter))) { |
|
16 | 16 | global $wpdb; |
17 | 17 | |
18 | 18 | $where = " AND {$wpdb->posts}.post_type = '" . WPSHOP_NEWTYPE_IDENTIFIER_CUSTOMERS . "'"; |
19 | 19 | |
20 | - if( !empty( $entity_filter ) ) { |
|
21 | - switch ( $entity_filter ) { |
|
20 | + if (!empty($entity_filter)) { |
|
21 | + switch ($entity_filter) { |
|
22 | 22 | case 'orders': |
23 | 23 | $operator = 'IN'; |
24 | 24 | break; |
@@ -35,9 +35,9 @@ discard block |
||
35 | 35 | )"; |
36 | 36 | } |
37 | 37 | |
38 | - if( !empty( $s ) ) { |
|
39 | - $s_soundex = soundex( $s ); |
|
40 | - $s = strtoupper( $s ); |
|
38 | + if (!empty($s)) { |
|
39 | + $s_soundex = soundex($s); |
|
40 | + $s = strtoupper($s); |
|
41 | 41 | $where .= " AND ( {$wpdb->posts}.ID = '{$s}' |
42 | 42 | OR UPPER( {$wpdb->posts}.post_title ) LIKE '%{$s}%' |
43 | 43 | OR SOUNDEX( {$wpdb->posts}.post_title ) = '{$s_soundex}' |
@@ -92,6 +92,6 @@ discard block |
||
92 | 92 | |
93 | 93 | } |
94 | 94 | |
95 | -if ( class_exists("wpshop_customer_search") ) { |
|
95 | +if (class_exists("wpshop_customer_search")) { |
|
96 | 96 | $wpshop_customer_search = new wpshop_customer_search(); |
97 | 97 | } |