Woocommerce Products Slider - Version 1.12.6

Version Description

  • 09/03/2017 update - Admin settings update, added new tab Elements.
    • 09/03/2017 add - on sale product display.
Download this release

Release Info

Developer pickplugins
Plugin Icon 128x128 Woocommerce Products Slider
Version 1.12.6
Comparing to
See all releases

Code changes from version 1.12.5 to 1.12.6

assets/admin/ParaAdmin/js/ParaAdmin.js CHANGED
@@ -3,19 +3,7 @@ jQuery(document).ready(function($)
3
  {
4
 
5
 
6
- $(document).on('click', '.expandable .header', function()
7
- {
8
- if($(this).parent().hasClass('active'))
9
- {
10
- $(this).parent().removeClass('active');
11
- }
12
- else
13
- {
14
- $(this).parent().addClass('active');
15
- }
16
-
17
-
18
- })
19
 
20
 
21
 
3
  {
4
 
5
 
6
+
 
 
 
 
 
 
 
 
 
 
 
 
7
 
8
 
9
 
assets/admin/css/style.css CHANGED
@@ -116,13 +116,42 @@
116
 
117
  #wcps_metabox .expandable .header {
118
  background: #a7e1ff none repeat scroll 0 0;
119
- padding-left: 20px;
 
 
 
 
 
 
 
120
  }
121
 
122
- #wcps_metabox .expandable .header:hover {
123
- background: #a7e1ff url("move.png") no-repeat scroll 7px 5px;
 
 
 
124
 
 
 
 
 
125
  }
126
 
 
 
 
127
 
 
 
 
128
 
 
 
 
 
 
 
 
 
 
116
 
117
  #wcps_metabox .expandable .header {
118
  background: #a7e1ff none repeat scroll 0 0;
119
+
120
+ }
121
+
122
+ #wcps_metabox .expandable .item {
123
+ background: #a7e1ff none repeat scroll 0 0;
124
+ /* border-bottom: 1px solid rgb(153, 153, 153); */
125
+ margin: 2px 0;
126
+ padding: 5px;
127
  }
128
 
129
+ #wcps_metabox .expandable .item .move {
130
+ display: inline-block;
131
+ padding: 5px;
132
+ cursor: move;
133
+ }
134
 
135
+ #wcps_metabox .expandable .item .expand {
136
+ display: inline-block;
137
+ padding: 5px;
138
+ cursor: pointer;
139
  }
140
 
141
+ #wcps_metabox .expandable .options {
142
+ background: #bde6fc;
143
+ }
144
 
145
+ #wcps_metabox .item .expand .fa-expand {
146
+ display: inline-block;
147
+ }
148
 
149
+ #wcps_metabox .item .expand .fa-compress {
150
+ display: none;
151
+ }
152
+ #wcps_metabox .item.active .expand .fa-compress {
153
+ display: inline-block;
154
+ }
155
+ #wcps_metabox .item.active .expand .fa-expand {
156
+ display: none;
157
+ }
assets/admin/js/scripts.js CHANGED
@@ -4,6 +4,23 @@ jQuery(document).ready(function($)
4
 
5
 
6
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
7
  $(document).on('click','.wcps_grid_items_reset',function(){
8
 
9
  if(confirm('Do you really want to reset ?')){
4
 
5
 
6
 
7
+ $(document).on('click', '#wcps_metabox .expandable .expand', function()
8
+ {
9
+ if($(this).parent().parent().hasClass('active'))
10
+ {
11
+ $(this).parent().parent().removeClass('active');
12
+ }
13
+ else
14
+ {
15
+ $(this).parent().parent().addClass('active');
16
+ }
17
+
18
+
19
+ })
20
+
21
+
22
+
23
+
24
  $(document).on('click','.wcps_grid_items_reset',function(){
25
 
26
  if(confirm('Do you really want to reset ?')){
includes/class-functions.php CHANGED
@@ -59,15 +59,15 @@ class class_wcps_functions {
59
  public function wcps_grid_items($grid_items = array()){
60
 
61
  $grid_items = array(
62
- 'thumb'=>__('Thumbnail','wcps'),
63
- 'title'=>__('Title','wcps'),
64
- 'excerpt'=>__('Excerpt','wcps'),
65
- 'category'=>__('Category','wcps'),
66
- 'price'=>__('Price','wcps'),
67
- 'rating'=>__('Rating','wcps'),
68
- 'cart'=>__('Cart','wcps'),
69
- 'sale'=>__('Sale','wcps'),
70
- 'featured'=>'Featured',
71
  );
72
  return $grid_items;
73
  }
59
  public function wcps_grid_items($grid_items = array()){
60
 
61
  $grid_items = array(
62
+ 'thumb'=>__('Thumbnail',wcps_textdomain),
63
+ 'title'=>__('Title',wcps_textdomain),
64
+ 'excerpt'=>__('Excerpt',wcps_textdomain),
65
+ 'category'=>__('Category',wcps_textdomain),
66
+ 'price'=>__('Price',wcps_textdomain),
67
+ 'rating'=>__('Rating',wcps_textdomain),
68
+ 'cart'=>__('Cart',wcps_textdomain),
69
+ 'sale'=>__('Sale',wcps_textdomain),
70
+ 'featured'=>__('Featured', wcps_textdomain),
71
  );
72
  return $grid_items;
73
  }
includes/class-settings.php CHANGED
@@ -18,7 +18,7 @@ class class_wcps_settings{
18
 
19
  public function admin_menu() {
20
 
21
- add_submenu_page('edit.php?post_type=wcps', __('Settings','wcps'), __('Settings','wcps'), 'manage_options', 'wcps_menu_settings', array( $this, 'settings_page' ));
22
 
23
 
24
  }
18
 
19
  public function admin_menu() {
20
 
21
+ add_submenu_page('edit.php?post_type=wcps', __('Settings',wcps_textdomain), __('Settings',wcps_textdomain), 'manage_options', 'wcps_menu_settings', array( $this, 'settings_page' ));
22
 
23
 
24
  }
includes/class-shortcodes.php CHANGED
@@ -51,13 +51,7 @@ class class_wcps_shortcodes{
51
  while ( $wp_query->have_posts() ) : $wp_query->the_post();
52
 
53
  global $product;
54
-
55
- $is_in_stock = $product->is_in_stock();
56
-
57
- if ( $wcps_hide_out_of_stock=='yes' && empty($is_in_stock) ) { continue; }
58
-
59
-
60
-
61
  $wcps_featured = get_post_meta( get_the_ID(), '_featured', true );
62
 
63
  $wcps_thumb = wp_get_attachment_image_src( get_post_thumbnail_id(get_the_ID()), $wcps_items_thumb_size );
@@ -73,14 +67,14 @@ class class_wcps_shortcodes{
73
 
74
  $sale_price = get_post_meta( get_the_ID(), '_sale_price', true);
75
 
76
- if($wcps_total_items_price_format=='full'){
77
  $price = $product->get_price_html();
78
  }
79
- elseif($wcps_total_items_price_format=='sale'){
80
 
81
  $price= $currency.get_post_meta( get_the_ID(), '_sale_price', true);
82
  }
83
- elseif($wcps_total_items_price_format=='regular'){
84
  $price = $currency.get_post_meta( get_the_ID(), '_regular_price', true);
85
  }
86
  else{
@@ -140,7 +134,7 @@ class class_wcps_shortcodes{
140
  wp_reset_query();
141
 
142
  else :
143
- $html.= __('No Product to Slide','wcps');
144
 
145
  endif;
146
 
51
  while ( $wp_query->have_posts() ) : $wp_query->the_post();
52
 
53
  global $product;
54
+
 
 
 
 
 
 
55
  $wcps_featured = get_post_meta( get_the_ID(), '_featured', true );
56
 
57
  $wcps_thumb = wp_get_attachment_image_src( get_post_thumbnail_id(get_the_ID()), $wcps_items_thumb_size );
67
 
68
  $sale_price = get_post_meta( get_the_ID(), '_sale_price', true);
69
 
70
+ if($wcps_items_price_format=='full'){
71
  $price = $product->get_price_html();
72
  }
73
+ elseif($wcps_items_price_format=='sale'){
74
 
75
  $price= $currency.get_post_meta( get_the_ID(), '_sale_price', true);
76
  }
77
+ elseif($wcps_items_price_format=='regular'){
78
  $price = $currency.get_post_meta( get_the_ID(), '_regular_price', true);
79
  }
80
  else{
134
  wp_reset_query();
135
 
136
  else :
137
+ $html.= __('No Product to Slide',wcps_textdomain);
138
 
139
  endif;
140
 
includes/functions.php CHANGED
@@ -81,7 +81,7 @@ function wcps_track_product_view() {
81
 
82
  function wcps_add_shortcode_column( $columns ) {
83
  return array_merge( $columns,
84
- array( 'shortcode' => __( 'Shortcode', 'wcps' ) ) );
85
  }
86
  add_filter( 'manage_wcps_posts_columns' , 'wcps_add_shortcode_column' );
87
 
@@ -173,7 +173,7 @@ function wcps_get_product_categories($postid)
173
 
174
  if(empty($categories))
175
  {
176
- echo __('No categories found!','wcps');
177
  $categories = array();
178
  }
179
 
81
 
82
  function wcps_add_shortcode_column( $columns ) {
83
  return array_merge( $columns,
84
+ array( 'shortcode' => __( 'Shortcode', wcps_textdomain ) ) );
85
  }
86
  add_filter( 'manage_wcps_posts_columns' , 'wcps_add_shortcode_column' );
87
 
173
 
174
  if(empty($categories))
175
  {
176
+ echo __('No categories found!',wcps_textdomain);
177
  $categories = array();
178
  }
179
 
includes/menu/settings.php CHANGED
@@ -33,7 +33,7 @@ if ( ! defined('ABSPATH')) exit; // if direct access
33
 
34
 
35
  ?>
36
- <div class="updated"><p><strong><?php _e('Changes Saved.','wcps' ); ?></strong></p></div>
37
 
38
  <?php
39
  }
@@ -53,7 +53,7 @@ if ( ! defined('ABSPATH')) exit; // if direct access
53
 
54
  <div class="wrap">
55
 
56
- <div id="icon-tools" class="icon32"><br></div><?php echo "<h2>".wcps_plugin_name.' '.__(' Settings','wcps')."</h2>";?>
57
  <form method="post" action="<?php echo str_replace( '%7E', '~', $_SERVER['REQUEST_URI']); ?>">
58
  <input type="hidden" name="wcps_hidden" value="Y">
59
  <?php settings_fields( 'wcps_plugin_options' );
@@ -64,8 +64,8 @@ if ( ! defined('ABSPATH')) exit; // if direct access
64
 
65
  <div class="para-settings">
66
  <ul class="tab-nav">
67
- <li nav="1" class="nav1 active"><i class="fa fa-cogs"></i> <?php _e('Options','wcps'); ?></li>
68
- <li nav="2" class="nav2"><i class="fa fa-hand-o-right"></i> <?php _e('Help','wcps'); ?></li>
69
  </ul> <!-- tab-nav end -->
70
 
71
  <ul class="box">
@@ -74,12 +74,12 @@ if ( ! defined('ABSPATH')) exit; // if direct access
74
  <li style="display: block;" class="box1 tab-box active">
75
 
76
  <div class="option-box">
77
- <p class="option-title"><?php _e('Track product View','wcps'); ?></p>
78
  <p class="option-info"></p>
79
 
80
  <select name="wcps_track_product_view" >
81
- <option value="no" <?php if($wcps_track_product_view=="no")echo "selected"; ?>><?php _e('No','wcps'); ?></option>
82
- <option value="yes" <?php if($wcps_track_product_view=="yes")echo "selected"; ?>><?php _e('Yes','wcps'); ?></option>
83
 
84
 
85
  </select>
@@ -92,16 +92,16 @@ if ( ! defined('ABSPATH')) exit; // if direct access
92
  <li style="display: none;" class="box2 tab-box">
93
 
94
  <div class="option-box">
95
- <p class="option-title"><?php _e('Need Help ?','wcps'); ?></p>
96
  <p class="option-info">
97
- <?php _e('Feel free to contact with any issue for this plugin, Ask any question via forum','wcps'); ?> <a href="<?php echo wcps_qa_url; ?>"><?php echo wcps_qa_url; ?></a> <strong style="color:#139b50;"><?php _e('(free)','wcps'); ?></strong><br />
98
 
99
  <?php
100
 
101
  if(wcps_customer_type=="free")
102
  {
103
 
104
- _e(sprintf('You are using <strong>%s version %s </strong> of <strong>%s</strong> To get more feature you could try our premium version.',wcps_customer_type, wcps_plugin_version, wcps_plugin_name),'wcps');
105
 
106
  // echo 'You are using <strong> '.wcps_customer_type.' version '.wcps_plugin_version.'</strong> of <strong>'.wcps_plugin_name.'</strong>, To get more feature you could try our premium version. ';
107
 
@@ -110,7 +110,7 @@ if ( ! defined('ABSPATH')) exit; // if direct access
110
  }
111
  else
112
  {
113
- _e(sprintf('Thanks for using <strong> premium version %s </strong> of <strong>%s</strong>.', wcps_plugin_version, wcps_plugin_name),'wcps');
114
  //echo 'Thanks for using <strong> premium version '.wcps_plugin_version.'</strong> of <strong>'.wcps_plugin_name.'</strong> ';
115
 
116
 
@@ -123,9 +123,9 @@ if ( ! defined('ABSPATH')) exit; // if direct access
123
 
124
  </div>
125
  <div class="option-box">
126
- <p class="option-title"><?php _e('Submit Reviews.','wcps'); ?></p>
127
  <p class="option-info">
128
- <?php _e('We are working hard to build some awesome plugins for you and spend thousand hour for plugins. we wish your three(3) minute by submitting five star reviews at wordpress.org. if you have any issue please submit at forum','wcps'); ?>
129
  .</p>
130
  <img src="<?php echo wcps_plugin_url."assets/admin/images/five-star.png";?>" /><br />
131
  <a target="_blank" href="<?php echo wcps_wp_reviews; ?>">
@@ -136,16 +136,16 @@ if ( ! defined('ABSPATH')) exit; // if direct access
136
 
137
  </div>
138
  <div class="option-box">
139
- <p class="option-title"><?php _e('Please Share','wcps'); ?></p>
140
- <p class="option-info"><?php _e('If you like this plugin please share with your social share network.','wcps'); ?></p>
141
  <?php
142
 
143
  echo wcps_share_plugin();
144
  ?>
145
  </div>
146
  <div class="option-box">
147
- <p class="option-title"><?php _e('Video Tutorial','wcps'); ?></p>
148
- <p class="option-info"><?php _e('Please watch this video tutorial.','wcps'); ?></p>
149
  <iframe width="640" height="480" src="<?php echo wcps_tutorial_video_url; ?>" frameborder="0" allowfullscreen></iframe>
150
  </div>
151
 
33
 
34
 
35
  ?>
36
+ <div class="updated"><p><strong><?php _e('Changes Saved.',wcps_textdomain ); ?></strong></p></div>
37
 
38
  <?php
39
  }
53
 
54
  <div class="wrap">
55
 
56
+ <div id="icon-tools" class="icon32"><br></div><?php echo "<h2>".wcps_plugin_name.' '.__(' Settings',wcps_textdomain)."</h2>";?>
57
  <form method="post" action="<?php echo str_replace( '%7E', '~', $_SERVER['REQUEST_URI']); ?>">
58
  <input type="hidden" name="wcps_hidden" value="Y">
59
  <?php settings_fields( 'wcps_plugin_options' );
64
 
65
  <div class="para-settings">
66
  <ul class="tab-nav">
67
+ <li nav="1" class="nav1 active"><i class="fa fa-cogs"></i> <?php _e('Options',wcps_textdomain); ?></li>
68
+ <li nav="2" class="nav2"><i class="fa fa-hand-o-right"></i> <?php _e('Help',wcps_textdomain); ?></li>
69
  </ul> <!-- tab-nav end -->
70
 
71
  <ul class="box">
74
  <li style="display: block;" class="box1 tab-box active">
75
 
76
  <div class="option-box">
77
+ <p class="option-title"><?php _e('Track product View',wcps_textdomain); ?></p>
78
  <p class="option-info"></p>
79
 
80
  <select name="wcps_track_product_view" >
81
+ <option value="no" <?php if($wcps_track_product_view=="no")echo "selected"; ?>><?php _e('No',wcps_textdomain); ?></option>
82
+ <option value="yes" <?php if($wcps_track_product_view=="yes")echo "selected"; ?>><?php _e('Yes',wcps_textdomain); ?></option>
83
 
84
 
85
  </select>
92
  <li style="display: none;" class="box2 tab-box">
93
 
94
  <div class="option-box">
95
+ <p class="option-title"><?php _e('Need Help ?',wcps_textdomain); ?></p>
96
  <p class="option-info">
97
+ <?php _e('Feel free to contact with any issue for this plugin, Ask any question via forum',wcps_textdomain); ?> <a href="<?php echo wcps_qa_url; ?>"><?php echo wcps_qa_url; ?></a> <strong style="color:#139b50;"><?php _e('(free)',wcps_textdomain); ?></strong><br />
98
 
99
  <?php
100
 
101
  if(wcps_customer_type=="free")
102
  {
103
 
104
+ _e(sprintf('You are using <strong>%s version %s </strong> of <strong>%s</strong> To get more feature you could try our premium version.',wcps_customer_type, wcps_plugin_version, wcps_plugin_name),wcps_textdomain);
105
 
106
  // echo 'You are using <strong> '.wcps_customer_type.' version '.wcps_plugin_version.'</strong> of <strong>'.wcps_plugin_name.'</strong>, To get more feature you could try our premium version. ';
107
 
110
  }
111
  else
112
  {
113
+ _e(sprintf('Thanks for using <strong> premium version %s </strong> of <strong>%s</strong>.', wcps_plugin_version, wcps_plugin_name),wcps_textdomain);
114
  //echo 'Thanks for using <strong> premium version '.wcps_plugin_version.'</strong> of <strong>'.wcps_plugin_name.'</strong> ';
115
 
116
 
123
 
124
  </div>
125
  <div class="option-box">
126
+ <p class="option-title"><?php _e('Submit Reviews.',wcps_textdomain); ?></p>
127
  <p class="option-info">
128
+ <?php _e('We are working hard to build some awesome plugins for you and spend thousand hour for plugins. we wish your three(3) minute by submitting five star reviews at wordpress.org. if you have any issue please submit at forum',wcps_textdomain); ?>
129
  .</p>
130
  <img src="<?php echo wcps_plugin_url."assets/admin/images/five-star.png";?>" /><br />
131
  <a target="_blank" href="<?php echo wcps_wp_reviews; ?>">
136
 
137
  </div>
138
  <div class="option-box">
139
+ <p class="option-title"><?php _e('Please Share',wcps_textdomain); ?></p>
140
+ <p class="option-info"><?php _e('If you like this plugin please share with your social share network.',wcps_textdomain); ?></p>
141
  <?php
142
 
143
  echo wcps_share_plugin();
144
  ?>
145
  </div>
146
  <div class="option-box">
147
+ <p class="option-title"><?php _e('Video Tutorial',wcps_textdomain); ?></p>
148
+ <p class="option-info"><?php _e('Please watch this video tutorial.',wcps_textdomain); ?></p>
149
  <iframe width="640" height="480" src="<?php echo wcps_tutorial_video_url; ?>" frameborder="0" allowfullscreen></iframe>
150
  </div>
151
 
includes/meta.php CHANGED
@@ -10,16 +10,16 @@ if ( ! defined('ABSPATH')) exit; // if direct access
10
  function wcps_posttype_register() {
11
 
12
  $labels = array(
13
- 'name' => __('WCPS', 'wcps'),
14
- 'singular_name' => __('WCPS', 'wcps'),
15
- 'add_new' => __('New WCPS', 'wcps'),
16
- 'add_new_item' => __('New WCPS','wcps'),
17
- 'edit_item' => __('Edit WCPS','wcps'),
18
- 'new_item' => __('New WCPS','wcps'),
19
- 'view_item' => __('View WCPS','wcps'),
20
- 'search_items' => __('Search WCPS','wcps'),
21
- 'not_found' => __('Nothing found','wcps'),
22
- 'not_found_in_trash' => __('Nothing found in Trash','wcps'),
23
  'parent_item_colon' => ''
24
  );
25
 
@@ -57,7 +57,7 @@ function meta_boxes_wcps()
57
  $screens = array( 'wcps' );
58
  foreach ( $screens as $screen )
59
  {
60
- add_meta_box('wcps_metabox',__( 'Woocommerce Products Slider Options','wcps' ),'meta_boxes_wcps_input', $screen);
61
  }
62
  }
63
  add_action( 'add_meta_boxes', 'meta_boxes_wcps' );
@@ -67,220 +67,141 @@ function meta_boxes_wcps_input( $post ) {
67
 
68
  global $post;
69
  wp_nonce_field( 'meta_boxes_wcps_input', 'meta_boxes_wcps_input_nonce' );
70
-
71
-
72
- $wcps_bg_img = get_post_meta( $post->ID, 'wcps_bg_img', true );
73
- $wcps_container_padding = get_post_meta( $post->ID, 'wcps_container_padding', true );
74
- if(empty($wcps_container_padding)){
75
- $wcps_container_padding = '';
76
- }
77
-
78
- $wcps_container_bg_color = get_post_meta( $post->ID, 'wcps_container_bg_color', true );
79
- if(empty($wcps_container_bg_color)){
80
- $wcps_container_bg_color = '';
81
- }
82
-
83
- $wcps_items_bg_color = get_post_meta( $post->ID, 'wcps_items_bg_color', true );
84
- if(empty($wcps_items_bg_color)){
85
-
86
- $wcps_items_bg_color = '';
87
- }
88
-
89
- $wcps_items_padding = get_post_meta( $post->ID, 'wcps_items_padding', true );
90
- if(empty($wcps_items_padding)){
91
- $wcps_items_padding = '';
92
-
93
- }
94
-
95
- $wcps_themes = get_post_meta( $post->ID, 'wcps_themes', true );
96
- if(empty($wcps_themes)){
97
- $wcps_themes = 'flat';
98
- }
99
-
100
-
101
- $wcps_total_items = get_post_meta( $post->ID, 'wcps_total_items', true );
102
- if(empty($wcps_total_items)){
103
- $wcps_total_items = 10;
104
- }
105
-
106
- $wcps_total_items_price_format = get_post_meta( $post->ID, 'wcps_total_items_price_format', true );
107
-
108
  $wcps_column_number = get_post_meta( $post->ID, 'wcps_column_number', true );
109
- if(empty($wcps_column_number)){
110
- $wcps_column_number = 3;
111
- }
112
  $wcps_column_number_tablet = get_post_meta( $post->ID, 'wcps_column_number_tablet', true );
113
- if(empty($wcps_column_number_tablet)){
114
- $wcps_column_number_tablet = 2;
115
- }
116
 
117
  $wcps_column_number_mobile = get_post_meta( $post->ID, 'wcps_column_number_mobile', true );
118
- if(empty($wcps_column_number_mobile)){
119
- $wcps_column_number_mobile = 1;
120
- }
121
 
122
  $wcps_auto_play = get_post_meta( $post->ID, 'wcps_auto_play', true );
123
- if(empty($wcps_auto_play)){
124
- $wcps_auto_play = 'true';
125
- }
126
-
127
-
128
  $wcps_rewind = get_post_meta( $post->ID, 'wcps_rewind', true );
129
  if(empty($wcps_rewind)){$wcps_rewind = 'true';}
130
 
131
  $wcps_loop = get_post_meta( $post->ID, 'wcps_loop', true );
132
- if(empty($wcps_loop)){$wcps_loop = 'true';}
133
 
134
  $wcps_center = get_post_meta( $post->ID, 'wcps_center', true );
135
  if(empty($wcps_center)){$wcps_center = 'false';}
136
-
137
- $wcps_slider_rtl = get_post_meta( $post->ID, 'wcps_slider_rtl', true );
138
- if(empty($wcps_slider_rtl)){$wcps_slider_rtl = 'false'; }
139
-
140
- $wcps_slider_animateout = get_post_meta( $post->ID, 'wcps_slider_animateout', true );
141
- if(empty($wcps_slider_animateout)){$wcps_slider_animateout = 'fadeOut'; }
142
-
143
- $wcps_slider_animatein = get_post_meta( $post->ID, 'wcps_slider_animatein', true );
144
- if(empty($wcps_slider_animatein)){$wcps_slider_animatein = 'flipInX'; }
145
-
146
- $wcps_stop_on_hover = get_post_meta( $post->ID, 'wcps_stop_on_hover', true );
147
- if(empty($wcps_stop_on_hover)){
148
- $wcps_stop_on_hover = 'true';
149
- }
150
 
 
 
151
 
152
  $wcps_slider_navigation = get_post_meta( $post->ID, 'wcps_slider_navigation', true );
153
- if(empty($wcps_slider_navigation)){
154
- $wcps_slider_navigation = 'true';
155
- }
156
-
157
 
158
  $wcps_slider_navigation_position = get_post_meta( $post->ID, 'wcps_slider_navigation_position', true );
159
- if(empty($wcps_slider_navigation_position)){
160
- $wcps_slider_navigation_position = 'topright';
161
- }
162
-
163
  $wcps_slide_speed = get_post_meta( $post->ID, 'wcps_slide_speed', true );
164
- if(empty($wcps_slide_speed)){
165
- $wcps_slide_speed = '1000';
166
- }
167
-
168
  $wcps_slider_pagination = get_post_meta( $post->ID, 'wcps_slider_pagination', true );
 
169
  $wcps_pagination_slide_speed = get_post_meta( $post->ID, 'wcps_pagination_slide_speed', true );
170
- if(empty($wcps_pagination_slide_speed)){
171
- $wcps_pagination_slide_speed = '1000';
172
- }
173
 
174
  $wcps_slider_pagination_count = get_post_meta( $post->ID, 'wcps_slider_pagination_count', true );
175
 
176
  $wcps_slider_pagination_bg = get_post_meta( $post->ID, 'wcps_slider_pagination_bg', true );
177
  $wcps_slider_pagination_text_color = get_post_meta( $post->ID, 'wcps_slider_pagination_text_color', true );
178
-
179
  $wcps_slider_touch_drag = get_post_meta( $post->ID, 'wcps_slider_touch_drag', true );
180
  $wcps_slider_mouse_drag = get_post_meta( $post->ID, 'wcps_slider_mouse_drag', true );
181
 
182
- $wcps_content_source = get_post_meta( $post->ID, 'wcps_content_source', true );
183
- if(empty($wcps_content_source)){
184
- $wcps_content_source = 'recent';
185
- }
186
 
187
- $wcps_content_year = get_post_meta( $post->ID, 'wcps_content_year', true );
188
- $wcps_content_month = get_post_meta( $post->ID, 'wcps_content_month', true );
189
- $wcps_content_month_year = get_post_meta( $post->ID, 'wcps_content_month_year', true );
190
 
191
- $wcps_content_sku = get_post_meta( $post->ID, 'wcps_content_sku', true );
 
192
 
193
- $wcps_taxonomy = get_post_meta( $post->ID, 'wcps_taxonomy', true );
194
- $wcps_taxonomy_category = get_post_meta( $post->ID, 'wcps_taxonomy_category', true );
 
 
 
 
 
 
 
195
 
196
- $wcps_product_ids = get_post_meta( $post->ID, 'wcps_product_ids', true );
 
 
 
 
 
 
197
 
198
- $wcps_items_cat_font_size = get_post_meta( $post->ID, 'wcps_items_cat_font_size', true );
199
- $wcps_items_cat_text_align = get_post_meta( $post->ID, 'wcps_items_cat_text_align', true );
200
 
201
- $wcps_featured_icon_url = get_post_meta( $post->ID, 'wcps_featured_icon_url', true );
 
202
 
203
- $wcps_sale_icon_url = get_post_meta( $post->ID, 'wcps_sale_icon_url', true );
204
-
205
- $wcps_ratings_text_align = get_post_meta( $post->ID, 'wcps_ratings_text_align', true );
206
- $wcps_items_ratings_font_size = get_post_meta( $post->ID, 'wcps_items_ratings_font_size', true );
207
- $wcps_items_ratings_color = get_post_meta( $post->ID, 'wcps_items_ratings_color', true );
208
-
209
- $wcps_cart_style = get_post_meta( $post->ID, 'wcps_cart_style', true );
210
- $wcps_cart_bg = get_post_meta( $post->ID, 'wcps_cart_bg', true );
211
- $wcps_cart_text_color = get_post_meta( $post->ID, 'wcps_cart_text_color', true );
212
- if(empty($wcps_cart_text_color)){
213
- $wcps_cart_text_color = '#626262';
214
- }
215
 
 
 
216
 
217
- $wcps_cart_text_align = get_post_meta( $post->ID, 'wcps_cart_text_align', true );
218
- $wcps_items_cat_font_color = get_post_meta( $post->ID, 'wcps_items_cat_font_color', true );
219
- if(empty($wcps_items_cat_font_color)){
220
- $wcps_items_cat_font_color = '#626262';
221
- }
222
 
223
  $wcps_grid_items = get_post_meta( $post->ID, 'wcps_grid_items', true );
224
  $wcps_grid_items_hide = get_post_meta( $post->ID, 'wcps_grid_items_hide', true );
225
 
 
 
 
 
 
 
 
226
  $wcps_items_title_color = get_post_meta( $post->ID, 'wcps_items_title_color', true );
227
- if(empty($wcps_items_title_color)){
228
- $wcps_items_title_color = '#626262';
229
- }
230
-
231
-
232
-
233
  $wcps_items_title_font_size = get_post_meta( $post->ID, 'wcps_items_title_font_size', true );
234
  $wcps_items_title_text_align = get_post_meta( $post->ID, 'wcps_items_title_text_align', true );
235
 
236
  $wcps_items_excerpt_count = get_post_meta( $post->ID, 'wcps_items_excerpt_count', true );
237
- if(empty($wcps_items_excerpt_count)){
238
- $wcps_items_excerpt_count = 20;
239
- }
240
 
241
  $wcps_items_excerpt_read_more = get_post_meta( $post->ID, 'wcps_items_excerpt_read_more', true );
242
- if(empty($wcps_items_excerpt_read_more)){
243
- $wcps_items_excerpt_read_more = 'View product.';
244
- }
245
-
246
-
247
-
248
  $wcps_items_excerpt_text_align = get_post_meta( $post->ID, 'wcps_items_excerpt_text_align', true );
249
  $wcps_items_excerpt_font_size = get_post_meta( $post->ID, 'wcps_items_excerpt_font_size', true );
250
  $wcps_items_excerpt_font_color = get_post_meta( $post->ID, 'wcps_items_excerpt_font_color', true );
251
- if(empty($wcps_items_excerpt_font_color)){
252
- $wcps_items_excerpt_font_color = '#626262';
253
- }
254
 
 
 
 
 
 
255
  $wcps_items_price_color = get_post_meta( $post->ID, 'wcps_items_price_color', true );
256
- if(empty($wcps_items_price_color)){
257
- $wcps_items_price_color = '#626262';
258
- }
259
-
260
-
261
-
262
-
263
  $wcps_items_price_font_size = get_post_meta( $post->ID, 'wcps_items_price_font_size', true );
264
  $wcps_items_price_text_align = get_post_meta( $post->ID, 'wcps_items_price_text_align', true );
265
 
266
- $wcps_items_thumb_link_to = get_post_meta( $post->ID, 'wcps_items_thumb_link_to', true );
267
- $wcps_items_thumb_size = get_post_meta( $post->ID, 'wcps_items_thumb_size', true );
268
- $wcps_items_thumb_max_hieght = get_post_meta( $post->ID, 'wcps_items_thumb_max_hieght', true );
269
- $wcps_items_thumb_zoom = get_post_meta( $post->ID, 'wcps_items_thumb_zoom', true );
270
-
271
- $wcps_items_empty_thumb = get_post_meta( $post->ID, 'wcps_items_empty_thumb', true );
272
- if(empty($wcps_items_empty_thumb)){
273
- $wcps_items_empty_thumb = wcps_plugin_url.'assets/front/images/no-thumb.png';
274
- }
275
-
276
 
 
 
 
 
277
 
278
- $wcps_query_order = get_post_meta( $post->ID, 'wcps_query_order', true );
279
- $wcps_query_orderby = get_post_meta( $post->ID, 'wcps_query_orderby', true );
280
- $wcps_hide_out_of_stock = get_post_meta( $post->ID, 'wcps_hide_out_of_stock', true );
281
 
282
- $wcps_ribbon_name = get_post_meta( $post->ID, 'wcps_ribbon_name', true );
283
- $wcps_ribbon_custom = get_post_meta( $post->ID, 'wcps_ribbon_custom', true );
284
 
285
  $wcps_items_custom_css = get_post_meta( $post->ID, 'wcps_items_custom_css', true );
286
 
@@ -296,22 +217,23 @@ function meta_boxes_wcps_input( $post ) {
296
 
297
  <div class="para-settings">
298
  <ul class="tab-nav">
299
- <li nav="1" class="nav1 active"><i class="fa fa-code"></i> <?php _e('Shortcode','wcps');?></li>
300
- <li nav="2" class="nav2"><i class="fa fa-cogs"></i> <?php _e('Options','wcps');?></li>
301
- <li nav="3" class="nav3"><i class="fa fa-diamond"></i> <?php _e('Style','wcps');?></li>
302
- <li nav="4" class="nav4"><i class="fa fa-pencil-square-o"></i> <?php _e('Content','wcps');?></li>
303
- <li nav="5" class="nav5"><i class="fa fa-bug"></i> <?php _e('Custom CSS','wcps');?></li>
 
304
  </ul> <!-- tab-nav end -->
305
 
306
  <ul class="box">
307
  <li style="display: block;" class="box1 tab-box active">
308
 
309
  <div class="option-box">
310
- <p class="option-title"><?php _e('Shortcode','wcps');?></p>
311
  <p class="option-info">
312
- <?php _e('Copy this shortcode and paste on page or post where you want to display slider.','wcps');?>
313
  <br />
314
- <?php _e('Use PHP code to your themes file to display slider.','wcps');?>
315
  </p>
316
  <textarea cols="50" rows="1" style="background:#bfefff" onClick="this.select();" >[wcps <?php echo 'id="'.$post->ID.'"';?>]</textarea>
317
  <br /><br />
@@ -323,22 +245,18 @@ function meta_boxes_wcps_input( $post ) {
323
 
324
 
325
  <li style="display: none;" class="box2 tab-box">
326
- <div class="option-box">
327
- <p class="option-title"><?php _e('Slider Total Items','wcps');?></p>
328
- <p class="option-info"><?php _e('ex: 10','wcps');?></p>
329
- <input type="text" placeholder="10" name="wcps_total_items" value="<?php echo $wcps_total_items; ?>" />
330
- </div>
331
 
332
  <div class="option-box">
333
- <p class="option-title"><?php _e('Slider Column Number','wcps');?></p>
334
 
335
- <p class="option-info"><?php _e('In Destop: (min:1000px and max)','wcps');?></p>
336
  <input type="text" placeholder="4" name="wcps_column_number" value="<?php echo $wcps_column_number; ?>" />
337
 
338
- <p class="option-info"><?php _e('In Tablet & Small Desktop: (900px max width)','wcps');?></p>
339
  <input type="text" placeholder="2" name="wcps_column_number_tablet" value="<?php echo $wcps_column_number_tablet; ?>" />
340
 
341
- <p class="option-info"><?php _e('In Mobile: (479px max width)','wcps');?></p>
342
  <input type="text" placeholder="1" name="wcps_column_number_mobile" value="<?php echo $wcps_column_number_mobile; ?>" />
343
 
344
 
@@ -346,13 +264,12 @@ function meta_boxes_wcps_input( $post ) {
346
  </div>
347
 
348
  <div class="option-box">
349
- <p class="option-title"><?php _e('Slider Auto Play','wcps');?></p>
350
- <p class="option-info"></p>
351
 
352
 
353
  <select name="wcps_auto_play">
354
- <option value="true" <?php if(($wcps_auto_play=="true")) echo "selected"; ?> ><?php _e('True','wcps');?></option>
355
- <option value="false" <?php if(($wcps_auto_play=="false")) echo "selected"; ?> ><?php _e('False','wcps');?></option>
356
  </select>
357
 
358
  <p class="option-info"><?php _e('Slider rewind', wcps_textdomain);?></p>
@@ -438,114 +355,97 @@ function meta_boxes_wcps_input( $post ) {
438
 
439
  </select>
440
 
441
-
442
-
443
- </div>
444
- <div class="option-box">
445
- <p class="option-title"><?php _e('Slider Stop on Hover','wcps');?></p>
446
- <p class="option-info"></p>
447
 
448
  <select name="wcps_stop_on_hover">
449
- <option value="true" <?php if(($wcps_stop_on_hover=="true")) echo "selected"; ?> ><?php _e('True','wcps');?></option>
450
- <option value="false" <?php if(($wcps_stop_on_hover=="false")) echo "selected"; ?> ><?php _e('False','wcps');?></option>
451
- </select>
452
-
453
-
454
- </div>
455
- <div class="option-box">
456
- <p class="option-title"><?php _e('Slider Navigation','wcps');?></p>
457
- <p class="option-info"><?php _e('Slider Navigation at Top','wcps');?></p>
458
 
459
  <select name="wcps_slider_navigation">
460
- <option value="true" <?php if(($wcps_slider_navigation=="true")) echo "selected"; ?> ><?php _e('True','wcps');?></option>
461
- <option value="false" <?php if(($wcps_slider_navigation=="false")) echo "selected"; ?> ><?php _e('False','wcps');?></option>
462
  </select>
463
 
464
 
465
- <p class="option-info"><?php _e('Slider Navigation Position','wcps');?></p>
466
  <select name="wcps_slider_navigation_position">
467
- <option value="topright" <?php if(($wcps_slider_navigation_position=="topright")) echo "selected"; ?> ><?php _e('Top Right','wcps');?></option>
468
- <option value="middle" <?php if(($wcps_slider_navigation_position=="middle")) echo "selected"; ?> ><?php _e('Middle','wcps');?></option>
469
- <option value="middle-fixed" <?php if(($wcps_slider_navigation_position=="middle-fixed")) echo "selected"; ?> ><?php _e('Middle fixed','wcps');?></option>
470
 
471
  </select>
472
-
473
-
474
- </div>
475
 
476
-
477
-
478
- <div class="option-box">
479
- <p class="option-title"><?php _e('Slider Pagination','wcps');?></p>
480
- <p class="option-info"><?php _e('Slider Pagination at Bottom','wcps');?></p>
481
 
482
  <select name="wcps_slider_pagination">
483
- <option value="true" <?php if(($wcps_slider_pagination=="true")) echo "selected"; ?> ><?php _e('True','wcps');?></option>
484
- <option value="false" <?php if(($wcps_slider_pagination=="false")) echo "selected"; ?> ><?php _e('False','wcps');?></option>
485
  </select>
486
-
487
-
488
-
489
- <p class="option-info"><?php _e('Pagination Background Color','wcps');?></p>
490
  <input type="text" name="wcps_slider_pagination_bg" class="wcps_color" id="wcps_slider_pagination_bg" value="<?php echo $wcps_slider_pagination_bg; ?>" />
491
 
492
- <p class="option-info"><?php _e('Pagination Text Color','wcps');?></p>
493
  <input type="text" name="wcps_slider_pagination_text_color" class="wcps_color" id="wcps_slider_pagination_text_color" value="<?php echo $wcps_slider_pagination_text_color; ?>" />
494
 
495
- <p class="option-info"><?php _e('Pagination Number Counting','wcps');?></p>
496
  <select name="wcps_slider_pagination_count">
497
- <option value="false" <?php if(($wcps_slider_pagination_count=="false")) echo "selected"; ?> ><?php _e('False','wcps');?></option>
498
- <option value="true" <?php if(($wcps_slider_pagination_count=="true")) echo "selected"; ?> ><?php _e('True','wcps');?></option>
499
 
500
  </select>
501
-
502
-
503
-
504
-
505
- </div>
506
-
507
 
508
-
509
-
510
- <div class="option-box">
511
- <p class="option-title"><?php _e('Slide Speed','wcps');?></p>
512
- <p class="option-info"></p>
513
- <input type="text" placeholder="1000" id="wcps_slide_speed" name="wcps_slide_speed" value="<?php echo $wcps_slide_speed; ?>" />
514
- </div>
515
- <div class="option-box">
516
- <p class="option-title"><?php _e('Pagination Slide Speed','wcps');?></p>
517
- <p class="option-info"></p>
518
- <input type="text" placeholder="1000" id="wcps_pagination_slide_speed" name="wcps_pagination_slide_speed" value="<?php echo $wcps_pagination_slide_speed; ?>" />
519
- </div>
520
-
521
- <div class="option-box">
522
- <p class="option-title"><?php _e('Slider Touch Drag Enabled','wcps');?></p>
523
- <p class="option-info"></p>
524
 
525
 
526
  <select name="wcps_slider_touch_drag">
527
- <option value="true" <?php if(($wcps_slider_touch_drag=="true")) echo "selected"; ?> ><?php _e('True','wcps');?></option>
528
- <option value="false" <?php if(($wcps_slider_touch_drag=="false")) echo "selected"; ?> ><?php _e('False','wcps');?></option>
529
  </select>
530
-
531
-
532
- </div>
533
- <div class="option-box">
534
- <p class="option-title"><?php _e('Slider Mouse Drag Enabled','wcps');?></p>
535
- <p class="option-info"></p>
536
 
537
  <select name="wcps_slider_mouse_drag">
538
- <option value="true" <?php if(($wcps_slider_mouse_drag=="true")) echo "selected"; ?> ><?php _e('True','wcps');?></option>
539
- <option value="false" <?php if(($wcps_slider_mouse_drag=="false")) echo "selected"; ?> ><?php _e('False','wcps');?></option>
540
  </select>
541
-
 
 
 
 
 
 
 
 
 
542
 
543
- </div>
 
 
 
 
 
544
 
545
  </li>
546
  <li style="display: none;" class="box3 tab-box ">
547
  <div class="option-box">
548
- <p class="option-title"><?php _e('Themes for slider','wcps');?></p>
549
  <p class="option-info"></p>
550
  <select name="wcps_themes" >
551
  <?php
@@ -568,7 +468,7 @@ function meta_boxes_wcps_input( $post ) {
568
 
569
 
570
  <div class="option-box">
571
- <p class="option-title"><?php _e('Slider Ribbon','wcps');?></p>
572
  <p class="option-info"></p>
573
  <?php
574
 
@@ -615,7 +515,7 @@ function meta_boxes_wcps_input( $post ) {
615
 
616
  ?>
617
 
618
- <input style="width:100%;" type="text" id="wcps_ribbon_custom" name="wcps_ribbon_custom" placeholder="Custom url for ribbons." id="wcps_ribbon_custom" value="<?php echo $wcps_ribbon_custom; ?>" />
619
 
620
  <?php
621
 
@@ -639,19 +539,19 @@ function meta_boxes_wcps_input( $post ) {
639
 
640
 
641
  <div class="option-box">
642
- <p class="option-title"><?php _e('Container options','wcps'); ?></p>
643
- <p class="option-info"><?php _e('Padding: (ex: 10px)','wcps'); ?></p>
644
  <input type="text" placeholder="10px" name="wcps_container_padding" value="<?php echo $wcps_container_padding; ?>" />
645
 
646
- <p class="option-info"><?php _e('Background color:','wcps'); ?></p>
647
  <input type="text" class="wcps_color" name="wcps_container_bg_color" value="<?php echo $wcps_container_bg_color; ?>" />
648
 
649
- <p class="option-info"><?php _e('Background image:','wcps'); ?></p>
650
  <img class="bg_image_src" onClick="bg_img_src(this)" src="<?php echo wcps_plugin_url; ?>assets/global/images/bg/dark_embroidery.png" />
651
  <img class="bg_image_src" onClick="bg_img_src(this)" src="<?php echo wcps_plugin_url; ?>assets/global/images/bg/dimension.png" />
652
  <img class="bg_image_src" onClick="bg_img_src(this)" src="<?php echo wcps_plugin_url; ?>assets/global/images/bg/eight_horns.png" />
653
  <br />
654
- <input type="text" id="wcps_bg_img" class="wcps_bg_img" name="wcps_bg_img" value="<?php echo $wcps_bg_img; ?>" /> <div onClick="clear_container_bg_image()" class="button clear-container-bg-image"> <?php _e('Clear','wcps'); ?></div>
655
 
656
  <script>
657
 
@@ -676,11 +576,11 @@ function meta_boxes_wcps_input( $post ) {
676
 
677
 
678
  <div class="option-box">
679
- <p class="option-title"><?php _e('Items Options','wcps'); ?></p>
680
- <p class="option-info"><?php _e('Items Background color','wcps'); ?></p>
681
  <input type="text" class="wcps_color" name="wcps_items_bg_color" value="<?php echo $wcps_items_bg_color; ?>" />
682
 
683
- <p class="option-info"><?php _e('Items Padding','wcps'); ?></p>
684
  <input type="text" name="wcps_items_padding" placeholder="5px" value="<?php echo $wcps_items_padding; ?>" />
685
 
686
  </div>
@@ -690,84 +590,19 @@ function meta_boxes_wcps_input( $post ) {
690
 
691
  </li>
692
  <li style="display: none;" class="box4 tab-box ">
693
-
694
- <div class="option-box">
695
- <p class="option-title"><?php _e('Empty Thumbnail','wcps');?></p>
696
- <p class="option-info"><?php _e('Custom thumbnail image url','wcps');?></p>
697
- <input type="text" name="wcps_items_empty_thumb" id="wcps_items_empty_thumb" value="<?php echo $wcps_items_empty_thumb; ?>" /><br /><br />
698
- <input id="wcps_items_empty_thumb_upload" class="wcps_items_empty_thumb_upload button" type="button" value="Upload Image" />
699
- <br /><br />
700
-
701
-
702
- <?php
703
- if(empty($wcps_items_empty_thumb))
704
- {
705
- ?>
706
- <img class="wcps_items_empty_thumb_display" width="300px" src="<?php echo wcps_plugin_url.'assets/front/images/no-thumb.png'; ?>" />
707
- <?php
708
- }
709
- else
710
- {
711
- ?>
712
- <img class="wcps_items_empty_thumb_display" width="300px" src="<?php echo $wcps_items_empty_thumb; ?>" />
713
- <?php
714
- }
715
- ?>
716
-
717
-
718
-
719
-
720
-
721
- <script>
722
- jQuery(document).ready(function($){
723
 
724
- var custom_uploader;
725
-
726
- jQuery('#wcps_items_empty_thumb_upload').click(function(e) {
727
-
728
- e.preventDefault();
729
-
730
- //If the uploader object has already been created, reopen the dialog
731
- if (custom_uploader) {
732
- custom_uploader.open();
733
- return;
734
- }
735
-
736
- //Extend the wp.media object
737
- custom_uploader = wp.media.frames.file_frame = wp.media({
738
- title: 'Choose Image',
739
- button: {
740
- text: 'Choose Image'
741
- },
742
- multiple: false
743
- });
744
-
745
- //When a file is selected, grab the URL and set it as the text field's value
746
- custom_uploader.on('select', function() {
747
- attachment = custom_uploader.state().get('selection').first().toJSON();
748
- jQuery('#wcps_items_empty_thumb').val(attachment.url);
749
- jQuery('.wcps_items_empty_thumb_display').attr('src',attachment.url);
750
- });
751
-
752
- //Open the uploader dialog
753
- custom_uploader.open();
754
-
755
- });
756
-
757
-
758
- })
759
- </script>
760
- </div>
761
-
762
-
763
 
764
  <div class="option-box">
765
- <p class="option-title"><?php _e('Query order','wcps'); ?></p>
766
  <p class="option-info"></p>
767
  <select name="wcps_query_order" >
768
- <option value="DESC" <?php if($wcps_query_order=="DESC") echo "selected"; ?>><?php _e('Descending','wcps');?></option>
769
- <option value="ASC" <?php if($wcps_query_order=="ASC") echo "selected"; ?>><?php _e('Ascending ','wcps');?></option>
770
-
771
 
772
  </select>
773
  </div>
@@ -778,71 +613,63 @@ function meta_boxes_wcps_input( $post ) {
778
 
779
 
780
  <div class="option-box">
781
- <p class="option-title"><?php _e('Query orderBy','wcps'); ?></p>
782
  <p class="option-info"></p>
783
  <select name="wcps_query_orderby" >
784
- <option value="none" <?php if($wcps_query_orderby=="none") echo "selected"; ?>><?php _e('None','wcps');?></option>
785
- <option value="ID" <?php if($wcps_query_orderby=="ID") echo "selected"; ?>><?php _e('ID','wcps');?></option>
786
- <option value="date" <?php if($wcps_query_orderby=="date") echo "selected"; ?>><?php _e('Date','wcps');?></option>
787
- <option value="rand" <?php if($wcps_query_orderby=="rand") echo "selected"; ?>><?php _e('Rand','wcps');?></option>
788
- <option value="comment_count" <?php if($wcps_query_orderby=="comment_count") echo "selected"; ?>><?php _e('Comment Count','wcps');?></option>
789
- <option value="author" <?php if($wcps_query_orderby=="author") echo "selected"; ?>><?php _e('Author','wcps');?></option>
790
- <option value="title" <?php if($wcps_query_orderby=="title") echo "selected"; ?>><?php _e('Title','wcps');?></option>
791
- <option value="name" <?php if($wcps_query_orderby=="name") echo "selected"; ?>><?php _e('Name','wcps');?></option>
792
- <option value="type" <?php if($wcps_query_orderby=="type") echo "selected"; ?>><?php _e('Type','wcps');?></option>
793
 
794
 
795
  </select>
796
  </div>
797
 
 
798
  <div class="option-box">
799
- <p class="option-title"><?php _e('Hide out of stock items','wcps'); ?></p>
800
- <p class="option-info"></p>
801
- <select name="wcps_hide_out_of_stock" >
802
- <option value="no" <?php if($wcps_hide_out_of_stock=="no") echo "selected"; ?>><?php _e('No','wcps');?></option>
803
- <option value="yes" <?php if($wcps_hide_out_of_stock=="yes") echo "selected"; ?>><?php _e('Yes ','wcps');?></option>
804
-
805
 
806
- </select>
807
- </div>
 
 
 
 
 
 
 
 
 
 
 
808
 
809
 
810
 
811
- <div class="option-box">
812
- <p class="option-title"><?php _e('Filter Slider Content.','wcps');?></p>
813
- <p class="option-info"></p>
814
- <ul class="content_source_area" >
815
- <li><input class="wcps_content_source" name="wcps_content_source" id="wcps_content_source_recent" type="radio" value="recent" <?php if($wcps_content_source=="recent") echo "checked";?> /> <label for="wcps_content_source_recent"><?php _e('Display from <b>Recent</b> Published','wcps');?></label>
816
- <div class="wcps_content_source_recent content-source-box"><?php _e('Slider items will query from recent published product.','wcps');?></div>
817
- </li>
818
-
819
- <li><input class="wcps_content_source" name="wcps_content_source" id="wcps_content_source_featured" type="radio" value="featured" <?php if($wcps_content_source=="featured") echo "checked";?> /> <label for="wcps_content_source_featured"><?php _e('Display from <b>Featured</b> Product','wcps');?></label>
820
- <div class="wcps_content_source_featured content-source-box"><?php _e('Slider items will query from featured marked product.','wcps');?></div>
821
- </li>
822
-
823
- <li><input class="wcps_content_source" name="wcps_content_source" id="wcps_content_source_year" type="radio" value="year" <?php if($wcps_content_source=="year") echo "checked";?> /> <label for="wcps_content_source_year"><?php _e('Display from Only <b>Year</b>','wcps');?></label>
824
-
825
- <div class="wcps_content_source_year content-source-box"><?php _e('Slider items will query from a year.','wcps');?>
826
- <input type="text" size="7" class="wcps_content_year" name="wcps_content_year" value="<?php echo $wcps_content_year;?>" placeholder="2014" />
827
- </div>
828
- </li>
829
-
830
- <li><input class="wcps_content_source" name="wcps_content_source" id="wcps_content_source_month" type="radio" value="month" <?php if($wcps_content_source=="month") echo "checked";?> /> <label for="wcps_content_source_month"><?php _e('Display from <b>Month</b>','wcps');?></label>
831
- <div class="wcps_content_source_month content-source-box"><?php _e('Slider items will query from Month of a year.','wcps');?> <br />
832
- <input type="text" size="7" class="wcps_content_month_year" name="wcps_content_month_year" value="<?php echo $wcps_content_month_year;?>" placeholder="2014" />
833
- <input type="text" size="7" class="wcps_content_month" name="wcps_content_month" value="<?php echo $wcps_content_month;?>" placeholder="06" />
834
- </div>
835
- </li>
836
 
 
 
 
 
 
 
837
 
838
-
839
- </ul>
840
- </div>
841
 
842
- <div class="option-box">
843
- <p class="option-title"><?php _e('Items sort.','wcps'); ?></p>
844
- <p class="option-info"><?php _e('Click each items to expand.','wcps'); ?></p>
845
- <div class="button wcps_grid_items_reset" wcps_id="<?php echo $wcps_id; ?>"><?php _e('Reset','wcps');?></div>
 
 
 
846
  <br /><br />
847
 
848
  <?php
@@ -871,47 +698,104 @@ function meta_boxes_wcps_input( $post ) {
871
 
872
 
873
  foreach($wcps_grid_items as $item_key=>$item_name){
874
- echo '<div class="items">';
875
- echo '<div class="header">'.$item_name;
876
- echo '<input type="hidden" name="wcps_grid_items['.$item_key.']" value="'.$item_name.'" />';
877
-
878
- if(!empty($wcps_grid_items_hide[$item_key])){
879
-
880
- $checked = 'checked';
881
- }
882
- else{
883
- $checked = '';
884
- }
885
-
886
- echo '<label><input '.$checked.' type="checkbox" class="wcps_grid_items_hide" name="wcps_grid_items_hide['.$item_key.']" value="1" />Hide on front-end</label>';
887
- //echo '<span class="remove">X</span>';
888
- echo '</div>'; // .header
889
-
890
-
891
- echo '<div class="options">';
892
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
893
  if($item_key == 'thumb'){
894
 
895
  ?>
896
  <div class="option-box">
897
- <p class="option-title"><?php _e('Slider Thumbnail Size','wcps');?></p>
898
  <p class="option-info"></p>
 
 
 
 
 
 
 
 
 
 
 
 
 
899
  <select name="wcps_items_thumb_size" >
900
- <option value="full" <?php if($wcps_items_thumb_size=="full")echo "selected"; ?>><?php _e('Full','wcps');?></option>
901
- <option value="large" <?php if($wcps_items_thumb_size=="large")echo "selected"; ?>><?php _e('Large','wcps');?></option>
902
- <option value="medium" <?php if($wcps_items_thumb_size=="medium")echo "selected"; ?>><?php _e('Medium','wcps');?></option>
903
- <option value="thumbnail" <?php if($wcps_items_thumb_size=="thumbnail")echo "selected"; ?>><?php _e('Thumbnail','wcps');?></option>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
904
 
905
  </select>
906
  </div>
907
 
908
 
909
  <div class="option-box">
910
- <p class="option-title"><?php _e('Items thumbnail link\'s to','wcps');?></p>
911
  <p class="option-info"></p>
912
  <select name="wcps_items_thumb_link_to" >
913
- <option value="product" <?php if($wcps_items_thumb_link_to=="product")echo "selected"; ?>><?php _e('Product','wcps');?></option>
914
- <option value="category" <?php if($wcps_items_thumb_link_to=="category")echo "selected"; ?>><?php _e('Category','wcps');?></option>
915
  </select>
916
  </div>
917
 
@@ -919,22 +803,93 @@ function meta_boxes_wcps_input( $post ) {
919
 
920
 
921
  <div class="option-box">
922
- <p class="option-title"><?php _e('Slider thumb max hieght(px)','wcps');?></p>
923
  <p class="option-info"></p>
924
  <input type="text" name="wcps_items_thumb_max_hieght" placeholder="14px" id="wcps_items_thumb_max_hieght" value="<?php echo $wcps_items_thumb_max_hieght; ?>" />
925
  </div>
926
 
927
  <div class="option-box">
928
- <p class="option-title"><?php _e('Display Thumbnail Zoom button','wcps');?></p>
929
  <p class="option-info"></p>
930
  <select name="wcps_items_thumb_zoom" >
931
- <option value="no" <?php if($wcps_items_thumb_zoom=="no")echo "selected"; ?>><?php _e('No','wcps');?></option>
932
- <option value="yes" <?php if($wcps_items_thumb_zoom=="yes")echo "selected"; ?>><?php _e('Yes','wcps');?></option>
933
 
934
  </select>
935
  </div>
936
 
937
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
938
  <?php
939
 
940
  }
@@ -942,34 +897,34 @@ function meta_boxes_wcps_input( $post ) {
942
 
943
  ?>
944
  <div class="option-box">
945
- <p class="option-title"><?php _e('Items Add to cart button Style','wcps');?></p>
946
- <p class="option-info"><?php _e('You can hide items Add to cart button on slider.','wcps');?></p>
947
  <select name="wcps_cart_style" >
948
- <option value="default" <?php if($wcps_cart_style=="default")echo "selected"; ?>><?php _e('Default','wcps');?></option>
949
- <option value="custom" <?php if($wcps_cart_style=="custom")echo "selected"; ?>><?php _e('Custom','wcps');?></option>
950
  </select>
951
  </div>
952
 
953
  <div class="option-box">
954
- <p class="option-title"><?php _e('Add to cart Background Color','wcps');?></p>
955
  <p class="option-info"></p>
956
  <input type="text" name="wcps_cart_bg" class="wcps_color" id="wcps_cart_bg" value="<?php echo $wcps_cart_bg; ?>" />
957
  </div>
958
 
959
  <div class="option-box">
960
- <p class="option-title"><?php _e('Add to cart Text Color','wcps');?></p>
961
  <p class="option-info"></p>
962
  <input type="text" name="wcps_cart_text_color" class="wcps_color" id="wcps_cart_text_color" value="<?php echo $wcps_cart_text_color; ?>" />
963
  </div>
964
 
965
  <div class="option-box">
966
- <p class="option-title"><?php _e('Items Cart Text Align','wcps');?></p>
967
 
968
 
969
  <select name="wcps_cart_text_align" >
970
- <option value="left" <?php if($wcps_cart_text_align=="left")echo "selected"; ?>><?php _e('Left','wcps');?></option>
971
- <option value="right" <?php if($wcps_cart_text_align=="right")echo "selected"; ?>><?php _e('Right','wcps');?></option>
972
- <option value="center" <?php if($wcps_cart_text_align=="center")echo "selected"; ?>><?php _e('Center','wcps');?></option>
973
  </select>
974
 
975
  </div>
@@ -985,7 +940,7 @@ function meta_boxes_wcps_input( $post ) {
985
 
986
 
987
  <div class="option-box">
988
- <p class="option-title"><?php _e('Sale marker icon url','wcps');?></p>
989
  <p class="option-info"></p>
990
  <input type="text" name="wcps_sale_icon_url" placeholder="" id="wcps_sale_icon_url" value="<?php echo $wcps_sale_icon_url; ?>" />
991
  </div>
@@ -1004,25 +959,25 @@ function meta_boxes_wcps_input( $post ) {
1004
 
1005
 
1006
  <div class="option-box">
1007
- <p class="option-title"><?php _e('Items Title Color','wcps');?></p>
1008
  <p class="option-info"></p>
1009
  <input type="text" name="wcps_items_title_color" class="wcps_color" id="wcps_items_title_color" value="<?php echo $wcps_items_title_color; ?>" />
1010
  </div>
1011
  <div class="option-box">
1012
- <p class="option-title"><?php _e('Items Title Font Size','wcps');?></p>
1013
  <p class="option-info"></p>
1014
  <input type="text" name="wcps_items_title_font_size" placeholder="14px" id="wcps_items_title_font_size" value="<?php echo $wcps_items_title_font_size; ?>" />
1015
  </div>
1016
 
1017
 
1018
  <div class="option-box">
1019
- <p class="option-title"><?php _e('Items Title Text Align','wcps');?></p>
1020
 
1021
 
1022
  <select name="wcps_items_title_text_align" >
1023
- <option value="left" <?php if($wcps_items_title_text_align=="left")echo "selected"; ?>><?php _e('Left','wcps');?></option>
1024
- <option value="right" <?php if($wcps_items_title_text_align=="right")echo "selected"; ?>><?php _e('Right','wcps');?></option>
1025
- <option value="center" <?php if($wcps_items_title_text_align=="center")echo "selected"; ?>><?php _e('Center','wcps');?></option>
1026
  </select>
1027
 
1028
  </div>
@@ -1035,7 +990,7 @@ function meta_boxes_wcps_input( $post ) {
1035
  ?>
1036
 
1037
  <div class="option-box">
1038
- <p class="option-title"><?php _e('Featured marker icon url','wcps');?></p>
1039
  <p class="option-info"></p>
1040
  <input type="text" name="wcps_featured_icon_url" placeholder="" id="wcps_featured_icon_url" value="<?php echo $wcps_featured_icon_url; ?>" />
1041
  </div>
@@ -1047,12 +1002,12 @@ function meta_boxes_wcps_input( $post ) {
1047
  ?>
1048
 
1049
  <div class="option-box">
1050
- <p class="option-title"><?php _e('Price format on slider','wcps');?></p>
1051
  <p class="option-info"></p>
1052
- <select name="wcps_total_items_price_format">
1053
- <option value="full" <?php if(($wcps_total_items_price_format=="full")) echo "selected"; ?> ><?php _e('Full Format','wcps');?></option>
1054
- <option value="sale" <?php if(($wcps_total_items_price_format=="sale")) echo "selected"; ?> ><?php _e('Sale price','wcps');?></option>
1055
- <option value="regular" <?php if(($wcps_total_items_price_format=="regular")) echo "selected"; ?> ><?php _e('Regular price','wcps');?></option>
1056
  </select>
1057
 
1058
  </div>
@@ -1061,13 +1016,13 @@ function meta_boxes_wcps_input( $post ) {
1061
 
1062
 
1063
  <div class="option-box">
1064
- <p class="option-title"><?php _e('Items Price Color','wcps');?></p>
1065
  <p class="option-info"></p>
1066
  <input type="text" name="wcps_items_price_color" class="wcps_color" id="wcps_items_price_color" value="<?php echo $wcps_items_price_color; ?>" />
1067
  </div>
1068
 
1069
  <div class="option-box">
1070
- <p class="option-title"><?php _e('Items price Font Size','wcps');?></p>
1071
  <p class="option-info"></p>
1072
  <input type="text" name="wcps_items_price_font_size" placeholder="14px" id="wcps_items_price_font_size" value="<?php echo $wcps_items_price_font_size; ?>" />
1073
  </div>
@@ -1075,13 +1030,13 @@ function meta_boxes_wcps_input( $post ) {
1075
 
1076
 
1077
  <div class="option-box">
1078
- <p class="option-title"><?php _e('Price Text Align','wcps');?></p>
1079
 
1080
 
1081
  <select name="wcps_items_price_text_align" >
1082
- <option value="left" <?php if($wcps_items_price_text_align=="left")echo "selected"; ?>><?php _e('Left','wcps');?></option>
1083
- <option value="right" <?php if($wcps_items_price_text_align=="right")echo "selected"; ?>><?php _e('Right','wcps');?></option>
1084
- <option value="center" <?php if($wcps_items_price_text_align=="center")echo "selected"; ?>><?php _e('Center','wcps');?></option>
1085
  </select>
1086
 
1087
  </div>
@@ -1100,27 +1055,27 @@ function meta_boxes_wcps_input( $post ) {
1100
  ?>
1101
 
1102
  <div class="option-box">
1103
- <p class="option-title"><?php _e('Items Rating Text Align','wcps');?></p>
1104
 
1105
 
1106
  <select name="wcps_ratings_text_align" >
1107
- <option value="left" <?php if($wcps_ratings_text_align=="left")echo "selected"; ?>><?php _e('Left','wcps');?></option>
1108
- <option value="right" <?php if($wcps_ratings_text_align=="right")echo "selected"; ?>><?php _e('Right','wcps');?></option>
1109
- <option value="center" <?php if($wcps_ratings_text_align=="center")echo "selected"; ?>><?php _e('Center','wcps');?></option>
1110
  </select>
1111
 
1112
  </div>
1113
 
1114
 
1115
  <div class="option-box">
1116
- <p class="option-title"><?php _e('Items ratings Font Size','wcps');?></p>
1117
  <p class="option-info"></p>
1118
  <input type="text" name="wcps_items_ratings_font_size" placeholder="14px" id="wcps_items_ratings_font_size" value="<?php echo $wcps_items_ratings_font_size; ?>" />
1119
  </div>
1120
 
1121
 
1122
  <div class="option-box">
1123
- <p class="option-title"><?php _e('Items Ratings Color','wcps');?></p>
1124
  <p class="option-info"></p>
1125
  <input type="text" name="wcps_items_ratings_color" class="wcps_color" id="wcps_items_ratings_color" value="<?php echo $wcps_items_ratings_color; ?>" />
1126
  </div>
@@ -1137,41 +1092,40 @@ function meta_boxes_wcps_input( $post ) {
1137
 
1138
  ?>
1139
  <div class="option-box">
1140
- <p class="option-title"><?php _e('Excerpt word count','wcps');?></p>
1141
  <p class="option-info"></p>
1142
  <input type="text" name="wcps_items_excerpt_count" placeholder="30" id="wcps_items_excerpt_count" value="<?php echo $wcps_items_excerpt_count; ?>" />
1143
  </div>
1144
 
1145
  <div class="option-box">
1146
- <p class="option-title"><?php _e('Excerpt read more text','wcps');?></p>
1147
  <p class="option-info"></p>
1148
  <input type="text" name="wcps_items_excerpt_read_more" placeholder="View product." id="wcps_items_excerpt_read_more" value="<?php echo $wcps_items_excerpt_read_more; ?>" />
1149
  </div>
1150
 
1151
  <div class="option-box">
1152
- <p class="option-title"><?php _e('Items Excerpt Font Size','wcps');?></p>
1153
  <p class="option-info"></p>
1154
  <input type="text" name="wcps_items_excerpt_font_size" placeholder="14px" id="wcps_items_excerpt_font_size" value="<?php echo $wcps_items_excerpt_font_size; ?>" />
1155
  </div>
1156
 
1157
 
1158
  <div class="option-box">
1159
- <p class="option-title"><?php _e('Excerpt Text Align','wcps');?></p>
1160
 
1161
 
1162
  <select name="wcps_items_excerpt_text_align" >
1163
- <option value="left" <?php if($wcps_items_excerpt_text_align=="left")echo "selected"; ?>><?php _e('Left','wcps');?></option>
1164
- <option value="right" <?php if($wcps_items_excerpt_text_align=="right")echo "selected"; ?>><?php _e('Right','wcps');?></option>
1165
-
1166
- <option value="center" <?php if($wcps_items_excerpt_text_align=="center")echo "selected"; ?>><?php _e('Center','wcps');?></option>
1167
  </select>
1168
 
1169
  </div>
1170
 
1171
  <div class="option-box">
1172
- <p class="option-title"><?php _e('Items Excerpt Font color','wcps');?></p>
1173
  <p class="option-info"></p>
1174
- <input type="text" class="wcps_color" name="wcps_items_excerpt_font_color" placeholder="14px" id="wcps_items_excerpt_font_color" value="<?php echo $wcps_items_excerpt_font_color; ?>" />
1175
  </div>
1176
 
1177
 
@@ -1191,20 +1145,20 @@ function meta_boxes_wcps_input( $post ) {
1191
 
1192
 
1193
  <div class="option-box">
1194
- <p class="option-title"><?php _e('Items Category Font Size','wcps');?></p>
1195
  <p class="option-info"></p>
1196
  <input type="text" name="wcps_items_cat_font_size" placeholder="14px" id="wcps_items_cat_font_size" value="<?php echo $wcps_items_cat_font_size; ?>" />
1197
  </div>
1198
 
1199
 
1200
  <div class="option-box">
1201
- <p class="option-title"><?php _e('Category Text Align','wcps');?></p>
1202
 
1203
 
1204
  <select name="wcps_items_cat_text_align" >
1205
- <option value="left" <?php if($wcps_items_cat_text_align=="left")echo "selected"; ?>><?php _e('Left','wcps');?></option>
1206
- <option value="right" <?php if($wcps_items_cat_text_align=="right")echo "selected"; ?>><?php _e('Right','wcps');?></option>
1207
- <option value="center" <?php if($wcps_items_cat_text_align=="center")echo "selected"; ?>><?php _e('Center','wcps');?></option>
1208
  </select>
1209
 
1210
  </div>
@@ -1213,9 +1167,9 @@ function meta_boxes_wcps_input( $post ) {
1213
 
1214
 
1215
  <div class="option-box">
1216
- <p class="option-title"><?php _e('Items Category Font color','wcps');?></p>
1217
  <p class="option-info"></p>
1218
- <input type="text" class="wcps_color" name="wcps_items_cat_font_color" placeholder="14px" id="wcps_items_cat_font_color" value="<?php echo $wcps_items_cat_font_color; ?>" />
1219
  </div>
1220
 
1221
 
@@ -1246,30 +1200,26 @@ function meta_boxes_wcps_input( $post ) {
1246
 
1247
  </div> <!-- .expandable -->
1248
 
 
 
 
 
 
 
 
 
 
1249
 
 
1250
 
1251
- </div>
1252
-
1253
- <script>
1254
- jQuery(document).ready(function($)
1255
- {
1256
- $(function() {
1257
- $( ".expandable" ).sortable({ handle: '.header' });
1258
- //$( ".items" ).disableSelection();
1259
- });
1260
-
1261
- })
1262
-
1263
- </script>
1264
-
1265
-
1266
- </li>
1267
 
 
1268
 
1269
- <li style="display: none;" class="box5 tab-box">
1270
  <div class="option-box">
1271
- <p class="option-title"><?php _e('Custom CSS for this slider.','wcps'); ?></p>
1272
- <p class="option-info"><?php _e('Do not use &lt;style>&lt;/style> tag, you can use bellow prefix to your css, sometime you need use "!important" to overrid.','wcps');?>
1273
  <br/>
1274
  <b>#wcps-<?php
1275
 
@@ -1350,7 +1300,7 @@ function meta_boxes_wcps_save( $post_id ) {
1350
 
1351
  $wcps_total_items = sanitize_text_field( $_POST['wcps_total_items'] );
1352
 
1353
- $wcps_total_items_price_format = sanitize_text_field( $_POST['wcps_total_items_price_format'] );
1354
 
1355
  $wcps_column_number = sanitize_text_field( $_POST['wcps_column_number'] );
1356
  $wcps_column_number_mobile = sanitize_text_field( $_POST['wcps_column_number_mobile'] );
@@ -1489,49 +1439,10 @@ function meta_boxes_wcps_save( $post_id ) {
1489
  {
1490
  $wcps_slider_mouse_drag = sanitize_text_field( $_POST['wcps_slider_mouse_drag'] );
1491
  }
1492
-
1493
-
1494
-
1495
- $wcps_content_source = sanitize_text_field( $_POST['wcps_content_source'] );
1496
- $wcps_content_year = sanitize_text_field( $_POST['wcps_content_year'] );
1497
- $wcps_content_month = sanitize_text_field( $_POST['wcps_content_month'] );
1498
- $wcps_content_month_year = sanitize_text_field( $_POST['wcps_content_month_year'] );
1499
-
1500
- $wcps_content_sku = sanitize_text_field( $_POST['wcps_content_sku'] );
1501
-
1502
-
1503
-
1504
- if(empty($_POST['wcps_taxonomy']))
1505
- {
1506
- $wcps_taxonomy = '';
1507
- }
1508
- else
1509
- {
1510
- $wcps_taxonomy = sanitize_text_field( $_POST['wcps_taxonomy'] );
1511
- }
1512
-
1513
-
1514
- if(empty($_POST['wcps_taxonomy_category']))
1515
- {
1516
- $wcps_taxonomy_category = '';
1517
- }
1518
- else
1519
- {
1520
- $wcps_taxonomy_category = stripslashes_deep( $_POST['wcps_taxonomy_category'] );
1521
- }
1522
-
1523
-
1524
- if(empty($_POST['wcps_product_ids']))
1525
- {
1526
- $wcps_product_ids = '';
1527
- }
1528
- else
1529
- {
1530
- $wcps_product_ids = sanitize_text_field( $_POST['wcps_product_ids'] );
1531
- }
1532
-
1533
 
1534
 
 
 
1535
 
1536
 
1537
  //$wcps_cat_display = sanitize_text_field( $_POST['wcps_cat_display'] );
@@ -1606,7 +1517,7 @@ function meta_boxes_wcps_save( $post_id ) {
1606
  update_post_meta( $post_id, 'wcps_themes', $wcps_themes );
1607
  update_post_meta( $post_id, 'wcps_total_items', $wcps_total_items );
1608
 
1609
- update_post_meta( $post_id, 'wcps_total_items_price_format', $wcps_total_items_price_format );
1610
 
1611
  update_post_meta( $post_id, 'wcps_column_number', $wcps_column_number );
1612
  update_post_meta( $post_id, 'wcps_column_number_mobile', $wcps_column_number_mobile );
@@ -1635,18 +1546,9 @@ function meta_boxes_wcps_save( $post_id ) {
1635
  update_post_meta( $post_id, 'wcps_slider_animateout', $wcps_slider_animateout );
1636
  update_post_meta( $post_id, 'wcps_slider_animatein', $wcps_slider_animatein );
1637
 
1638
-
1639
- update_post_meta( $post_id, 'wcps_content_source', $wcps_content_source );
1640
- update_post_meta( $post_id, 'wcps_content_year', $wcps_content_year );
1641
- update_post_meta( $post_id, 'wcps_content_month', $wcps_content_month );
1642
- update_post_meta( $post_id, 'wcps_content_month_year', $wcps_content_month_year );
1643
-
1644
- update_post_meta( $post_id, 'wcps_content_sku', $wcps_content_sku );
1645
-
1646
- update_post_meta( $post_id, 'wcps_taxonomy', $wcps_taxonomy );
1647
- update_post_meta( $post_id, 'wcps_taxonomy_category', $wcps_taxonomy_category );
1648
-
1649
- update_post_meta( $post_id, 'wcps_product_ids', $wcps_product_ids );
1650
 
1651
  //update_post_meta( $post_id, 'wcps_cat_display', $wcps_cat_display );
1652
  update_post_meta( $post_id, 'wcps_items_cat_font_size', $wcps_items_cat_font_size );
10
  function wcps_posttype_register() {
11
 
12
  $labels = array(
13
+ 'name' => __('WCPS', wcps_textdomain),
14
+ 'singular_name' => __('WCPS', wcps_textdomain),
15
+ 'add_new' => __('New WCPS', wcps_textdomain),
16
+ 'add_new_item' => __('New WCPS',wcps_textdomain),
17
+ 'edit_item' => __('Edit WCPS',wcps_textdomain),
18
+ 'new_item' => __('New WCPS',wcps_textdomain),
19
+ 'view_item' => __('View WCPS',wcps_textdomain),
20
+ 'search_items' => __('Search WCPS',wcps_textdomain),
21
+ 'not_found' => __('Nothing found',wcps_textdomain),
22
+ 'not_found_in_trash' => __('Nothing found in Trash',wcps_textdomain),
23
  'parent_item_colon' => ''
24
  );
25
 
57
  $screens = array( 'wcps' );
58
  foreach ( $screens as $screen )
59
  {
60
+ add_meta_box('wcps_metabox',__( 'Woocommerce Products Slider Options',wcps_textdomain ),'meta_boxes_wcps_input', $screen);
61
  }
62
  }
63
  add_action( 'add_meta_boxes', 'meta_boxes_wcps' );
67
 
68
  global $post;
69
  wp_nonce_field( 'meta_boxes_wcps_input', 'meta_boxes_wcps_input_nonce' );
70
+
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
71
  $wcps_column_number = get_post_meta( $post->ID, 'wcps_column_number', true );
72
+ if(empty($wcps_column_number)){ $wcps_column_number = 3; }
73
+
 
74
  $wcps_column_number_tablet = get_post_meta( $post->ID, 'wcps_column_number_tablet', true );
75
+ if(empty($wcps_column_number_tablet)){ $wcps_column_number_tablet = 2; }
 
 
76
 
77
  $wcps_column_number_mobile = get_post_meta( $post->ID, 'wcps_column_number_mobile', true );
78
+ if(empty($wcps_column_number_mobile)){ $wcps_column_number_mobile = 1; }
 
 
79
 
80
  $wcps_auto_play = get_post_meta( $post->ID, 'wcps_auto_play', true );
81
+ if(empty($wcps_auto_play)){ $wcps_auto_play = 'true'; }
82
+
 
 
 
83
  $wcps_rewind = get_post_meta( $post->ID, 'wcps_rewind', true );
84
  if(empty($wcps_rewind)){$wcps_rewind = 'true';}
85
 
86
  $wcps_loop = get_post_meta( $post->ID, 'wcps_loop', true );
87
+ if(empty($wcps_loop)){$wcps_loop = 'true';}
88
 
89
  $wcps_center = get_post_meta( $post->ID, 'wcps_center', true );
90
  if(empty($wcps_center)){$wcps_center = 'false';}
 
 
 
 
 
 
 
 
 
 
 
 
 
 
91
 
92
+ $wcps_stop_on_hover = get_post_meta( $post->ID, 'wcps_stop_on_hover', true );
93
+ if(empty($wcps_stop_on_hover)){ $wcps_stop_on_hover = 'true'; }
94
 
95
  $wcps_slider_navigation = get_post_meta( $post->ID, 'wcps_slider_navigation', true );
96
+ if(empty($wcps_slider_navigation)){ $wcps_slider_navigation = 'true'; }
 
 
 
97
 
98
  $wcps_slider_navigation_position = get_post_meta( $post->ID, 'wcps_slider_navigation_position', true );
99
+ if(empty($wcps_slider_navigation_position)){$wcps_slider_navigation_position = 'topright'; }
100
+
 
 
101
  $wcps_slide_speed = get_post_meta( $post->ID, 'wcps_slide_speed', true );
102
+ if(empty($wcps_slide_speed)){$wcps_slide_speed = '1000'; }
103
+
 
 
104
  $wcps_slider_pagination = get_post_meta( $post->ID, 'wcps_slider_pagination', true );
105
+
106
  $wcps_pagination_slide_speed = get_post_meta( $post->ID, 'wcps_pagination_slide_speed', true );
107
+ if(empty($wcps_pagination_slide_speed)){$wcps_pagination_slide_speed = '1000'; }
 
 
108
 
109
  $wcps_slider_pagination_count = get_post_meta( $post->ID, 'wcps_slider_pagination_count', true );
110
 
111
  $wcps_slider_pagination_bg = get_post_meta( $post->ID, 'wcps_slider_pagination_bg', true );
112
  $wcps_slider_pagination_text_color = get_post_meta( $post->ID, 'wcps_slider_pagination_text_color', true );
113
+
114
  $wcps_slider_touch_drag = get_post_meta( $post->ID, 'wcps_slider_touch_drag', true );
115
  $wcps_slider_mouse_drag = get_post_meta( $post->ID, 'wcps_slider_mouse_drag', true );
116
 
117
+ $wcps_slider_rtl = get_post_meta( $post->ID, 'wcps_slider_rtl', true );
118
+ if(empty($wcps_slider_rtl)){$wcps_slider_rtl = 'false'; }
 
 
119
 
120
+ $wcps_slider_animateout = get_post_meta( $post->ID, 'wcps_slider_animateout', true );
121
+ if(empty($wcps_slider_animateout)){$wcps_slider_animateout = 'fadeOut'; }
 
122
 
123
+ $wcps_slider_animatein = get_post_meta( $post->ID, 'wcps_slider_animatein', true );
124
+ if(empty($wcps_slider_animatein)){$wcps_slider_animatein = 'flipInX'; }
125
 
126
+
127
+ $wcps_themes = get_post_meta( $post->ID, 'wcps_themes', true );
128
+ if(empty($wcps_themes)){ $wcps_themes = 'flat'; }
129
+
130
+ $wcps_ribbon_name = get_post_meta( $post->ID, 'wcps_ribbon_name', true );
131
+ $wcps_ribbon_custom = get_post_meta( $post->ID, 'wcps_ribbon_custom', true );
132
+
133
+ $wcps_container_padding = get_post_meta( $post->ID, 'wcps_container_padding', true );
134
+ if(empty($wcps_container_padding)){ $wcps_container_padding = ''; }
135
 
136
+ $wcps_container_bg_color = get_post_meta( $post->ID, 'wcps_container_bg_color', true );
137
+ if(empty($wcps_container_bg_color)){ $wcps_container_bg_color = ''; }
138
+
139
+ $wcps_bg_img = get_post_meta( $post->ID, 'wcps_bg_img', true );
140
+
141
+ $wcps_items_bg_color = get_post_meta( $post->ID, 'wcps_items_bg_color', true );
142
+ if(empty($wcps_items_bg_color)){$wcps_items_bg_color = ''; }
143
 
144
+ $wcps_items_padding = get_post_meta( $post->ID, 'wcps_items_padding', true );
145
+ if(empty($wcps_items_padding)){ $wcps_items_padding = ''; }
146
 
147
+ $wcps_total_items = get_post_meta( $post->ID, 'wcps_total_items', true );
148
+ if(empty($wcps_total_items)){ $wcps_total_items = -1;}
149
 
150
+ $wcps_query_order = get_post_meta( $post->ID, 'wcps_query_order', true );
151
+ $wcps_query_orderby = get_post_meta( $post->ID, 'wcps_query_orderby', true );
152
+ $wcps_hide_out_of_stock = get_post_meta( $post->ID, 'wcps_hide_out_of_stock', true );
 
 
 
 
 
 
 
 
 
153
 
154
+ $wcps_product_featured = get_post_meta( $post->ID, 'wcps_product_featured', true );
155
+ if(empty($wcps_product_featured)){ $wcps_product_featured = 'no'; }
156
 
157
+ $wcps_product_on_sale = get_post_meta( $post->ID, 'wcps_product_on_sale', true );
158
+ if(empty($wcps_product_on_sale)){ $wcps_product_on_sale = 'no'; }
 
 
 
159
 
160
  $wcps_grid_items = get_post_meta( $post->ID, 'wcps_grid_items', true );
161
  $wcps_grid_items_hide = get_post_meta( $post->ID, 'wcps_grid_items_hide', true );
162
 
163
+ $wcps_items_thumb_size = get_post_meta( $post->ID, 'wcps_items_thumb_size', true );
164
+ $wcps_items_thumb_link_to = get_post_meta( $post->ID, 'wcps_items_thumb_link_to', true );
165
+ $wcps_items_thumb_max_hieght = get_post_meta( $post->ID, 'wcps_items_thumb_max_hieght', true );
166
+ $wcps_items_thumb_zoom = get_post_meta( $post->ID, 'wcps_items_thumb_zoom', true );
167
+ $wcps_items_empty_thumb = get_post_meta( $post->ID, 'wcps_items_empty_thumb', true );
168
+ if(empty($wcps_items_empty_thumb)){ $wcps_items_empty_thumb = wcps_plugin_url.'assets/front/images/no-thumb.png'; }
169
+
170
  $wcps_items_title_color = get_post_meta( $post->ID, 'wcps_items_title_color', true );
 
 
 
 
 
 
171
  $wcps_items_title_font_size = get_post_meta( $post->ID, 'wcps_items_title_font_size', true );
172
  $wcps_items_title_text_align = get_post_meta( $post->ID, 'wcps_items_title_text_align', true );
173
 
174
  $wcps_items_excerpt_count = get_post_meta( $post->ID, 'wcps_items_excerpt_count', true );
175
+ if(empty($wcps_items_excerpt_count)){$wcps_items_excerpt_count = 20;}
 
 
176
 
177
  $wcps_items_excerpt_read_more = get_post_meta( $post->ID, 'wcps_items_excerpt_read_more', true );
178
+ if(empty($wcps_items_excerpt_read_more)){$wcps_items_excerpt_read_more = __('View product.', wcps_textdomain);}
179
+
 
 
 
 
180
  $wcps_items_excerpt_text_align = get_post_meta( $post->ID, 'wcps_items_excerpt_text_align', true );
181
  $wcps_items_excerpt_font_size = get_post_meta( $post->ID, 'wcps_items_excerpt_font_size', true );
182
  $wcps_items_excerpt_font_color = get_post_meta( $post->ID, 'wcps_items_excerpt_font_color', true );
 
 
 
183
 
184
+ $wcps_items_cat_font_size = get_post_meta( $post->ID, 'wcps_items_cat_font_size', true );
185
+ $wcps_items_cat_text_align = get_post_meta( $post->ID, 'wcps_items_cat_text_align', true );
186
+ $wcps_items_cat_font_color = get_post_meta( $post->ID, 'wcps_items_cat_font_color', true );
187
+
188
+ $wcps_items_price_format = get_post_meta( $post->ID, 'wcps_items_price_format', true );
189
  $wcps_items_price_color = get_post_meta( $post->ID, 'wcps_items_price_color', true );
 
 
 
 
 
 
 
190
  $wcps_items_price_font_size = get_post_meta( $post->ID, 'wcps_items_price_font_size', true );
191
  $wcps_items_price_text_align = get_post_meta( $post->ID, 'wcps_items_price_text_align', true );
192
 
193
+ $wcps_ratings_text_align = get_post_meta( $post->ID, 'wcps_ratings_text_align', true );
194
+ $wcps_items_ratings_font_size = get_post_meta( $post->ID, 'wcps_items_ratings_font_size', true );
195
+ $wcps_items_ratings_color = get_post_meta( $post->ID, 'wcps_items_ratings_color', true );
 
 
 
 
 
 
 
196
 
197
+ $wcps_cart_style = get_post_meta( $post->ID, 'wcps_cart_style', true );
198
+ $wcps_cart_bg = get_post_meta( $post->ID, 'wcps_cart_bg', true );
199
+ $wcps_cart_text_color = get_post_meta( $post->ID, 'wcps_cart_text_color', true );
200
+ $wcps_cart_text_align = get_post_meta( $post->ID, 'wcps_cart_text_align', true );
201
 
202
+ $wcps_sale_icon_url = get_post_meta( $post->ID, 'wcps_sale_icon_url', true );
 
 
203
 
204
+ $wcps_featured_icon_url = get_post_meta( $post->ID, 'wcps_featured_icon_url', true );
 
205
 
206
  $wcps_items_custom_css = get_post_meta( $post->ID, 'wcps_items_custom_css', true );
207
 
217
 
218
  <div class="para-settings">
219
  <ul class="tab-nav">
220
+ <li nav="1" class="nav1 active"><i class="fa fa-code"></i> <?php _e('Shortcode',wcps_textdomain);?></li>
221
+ <li nav="2" class="nav2"><i class="fa fa-cogs"></i> <?php _e('Options',wcps_textdomain);?></li>
222
+ <li nav="3" class="nav3"><i class="fa fa-diamond"></i> <?php _e('Style',wcps_textdomain);?></li>
223
+ <li nav="4" class="nav4"><i class="fa fa-pencil-square-o"></i> <?php _e('Query Product',wcps_textdomain);?></li>
224
+ <li nav="5" class="nav5"><i class="fa fa-pencil-square-o"></i> <?php _e('Elements', wcps_textdomain);?></li>
225
+ <li nav="6" class="nav6"><i class="fa fa-bug"></i> <?php _e('Custom CSS',wcps_textdomain);?></li>
226
  </ul> <!-- tab-nav end -->
227
 
228
  <ul class="box">
229
  <li style="display: block;" class="box1 tab-box active">
230
 
231
  <div class="option-box">
232
+ <p class="option-title"><?php _e('Shortcode',wcps_textdomain);?></p>
233
  <p class="option-info">
234
+ <?php _e('Copy this shortcode and paste on page or post where you want to display slider.',wcps_textdomain);?>
235
  <br />
236
+ <?php _e('Use PHP code to your themes file to display slider.',wcps_textdomain);?>
237
  </p>
238
  <textarea cols="50" rows="1" style="background:#bfefff" onClick="this.select();" >[wcps <?php echo 'id="'.$post->ID.'"';?>]</textarea>
239
  <br /><br />
245
 
246
 
247
  <li style="display: none;" class="box2 tab-box">
248
+
 
 
 
 
249
 
250
  <div class="option-box">
251
+ <p class="option-title"><?php _e('Slider column number',wcps_textdomain);?></p>
252
 
253
+ <p class="option-info"><?php _e('In Destop: (min:1000px and max)',wcps_textdomain);?></p>
254
  <input type="text" placeholder="4" name="wcps_column_number" value="<?php echo $wcps_column_number; ?>" />
255
 
256
+ <p class="option-info"><?php _e('In Tablet & Small Desktop: (900px max width)',wcps_textdomain);?></p>
257
  <input type="text" placeholder="2" name="wcps_column_number_tablet" value="<?php echo $wcps_column_number_tablet; ?>" />
258
 
259
+ <p class="option-info"><?php _e('In Mobile: (479px max width)',wcps_textdomain);?></p>
260
  <input type="text" placeholder="1" name="wcps_column_number_mobile" value="<?php echo $wcps_column_number_mobile; ?>" />
261
 
262
 
264
  </div>
265
 
266
  <div class="option-box">
267
+ <p class="option-info"><?php _e('Slider Auto Play',wcps_textdomain);?></p>
 
268
 
269
 
270
  <select name="wcps_auto_play">
271
+ <option value="true" <?php if(($wcps_auto_play=="true")) echo "selected"; ?> ><?php _e('True',wcps_textdomain);?></option>
272
+ <option value="false" <?php if(($wcps_auto_play=="false")) echo "selected"; ?> ><?php _e('False',wcps_textdomain);?></option>
273
  </select>
274
 
275
  <p class="option-info"><?php _e('Slider rewind', wcps_textdomain);?></p>
355
 
356
  </select>
357
 
358
+ <p class="option-info"><?php _e('Slider Stop on Hover',wcps_textdomain);?></p>
 
 
 
 
 
359
 
360
  <select name="wcps_stop_on_hover">
361
+ <option value="true" <?php if(($wcps_stop_on_hover=="true")) echo "selected"; ?> ><?php _e('True',wcps_textdomain);?></option>
362
+ <option value="false" <?php if(($wcps_stop_on_hover=="false")) echo "selected"; ?> ><?php _e('False',wcps_textdomain);?></option>
363
+ </select>
364
+
365
+ <p class="option-info"><?php _e('Slider Navigation at Top',wcps_textdomain);?></p>
 
 
 
 
366
 
367
  <select name="wcps_slider_navigation">
368
+ <option value="true" <?php if(($wcps_slider_navigation=="true")) echo "selected"; ?> ><?php _e('True',wcps_textdomain);?></option>
369
+ <option value="false" <?php if(($wcps_slider_navigation=="false")) echo "selected"; ?> ><?php _e('False',wcps_textdomain);?></option>
370
  </select>
371
 
372
 
373
+ <p class="option-info"><?php _e('Slider Navigation Position',wcps_textdomain);?></p>
374
  <select name="wcps_slider_navigation_position">
375
+ <option value="topright" <?php if(($wcps_slider_navigation_position=="topright")) echo "selected"; ?> ><?php _e('Top Right',wcps_textdomain);?></option>
376
+ <option value="middle" <?php if(($wcps_slider_navigation_position=="middle")) echo "selected"; ?> ><?php _e('Middle',wcps_textdomain);?></option>
377
+ <option value="middle-fixed" <?php if(($wcps_slider_navigation_position=="middle-fixed")) echo "selected"; ?> ><?php _e('Middle fixed',wcps_textdomain);?></option>
378
 
379
  </select>
 
 
 
380
 
381
+ <p class="option-info"><?php _e('Slide Speed',wcps_textdomain);?></p>
382
+ <input type="text" placeholder="1000" id="wcps_slide_speed" name="wcps_slide_speed" value="<?php echo $wcps_slide_speed; ?>" />
383
+
384
+
385
+ <p class="option-info"><?php _e('Slider Pagination at Bottom',wcps_textdomain);?></p>
386
 
387
  <select name="wcps_slider_pagination">
388
+ <option value="true" <?php if(($wcps_slider_pagination=="true")) echo "selected"; ?> ><?php _e('True',wcps_textdomain);?></option>
389
+ <option value="false" <?php if(($wcps_slider_pagination=="false")) echo "selected"; ?> ><?php _e('False',wcps_textdomain);?></option>
390
  </select>
391
+
392
+
393
+
394
+ <p class="option-info"><?php _e('Pagination Background Color',wcps_textdomain);?></p>
395
  <input type="text" name="wcps_slider_pagination_bg" class="wcps_color" id="wcps_slider_pagination_bg" value="<?php echo $wcps_slider_pagination_bg; ?>" />
396
 
397
+ <p class="option-info"><?php _e('Pagination Text Color',wcps_textdomain);?></p>
398
  <input type="text" name="wcps_slider_pagination_text_color" class="wcps_color" id="wcps_slider_pagination_text_color" value="<?php echo $wcps_slider_pagination_text_color; ?>" />
399
 
400
+ <p class="option-info"><?php _e('Pagination Number Counting',wcps_textdomain);?></p>
401
  <select name="wcps_slider_pagination_count">
402
+ <option value="false" <?php if(($wcps_slider_pagination_count=="false")) echo "selected"; ?> ><?php _e('False',wcps_textdomain);?></option>
403
+ <option value="true" <?php if(($wcps_slider_pagination_count=="true")) echo "selected"; ?> ><?php _e('True',wcps_textdomain);?></option>
404
 
405
  </select>
 
 
 
 
 
 
406
 
407
+
408
+
409
+ <p class="option-info"><?php _e('Pagination Slide Speed',wcps_textdomain);?></p>
410
+ <input type="text" placeholder="1000" id="wcps_pagination_slide_speed" name="wcps_pagination_slide_speed" value="<?php echo $wcps_pagination_slide_speed; ?>" />
411
+
412
+ <p class="option-info"><?php _e('Slider Touch Drag Enabled',wcps_textdomain);?></p>
 
 
 
 
 
 
 
 
 
 
413
 
414
 
415
  <select name="wcps_slider_touch_drag">
416
+ <option value="true" <?php if(($wcps_slider_touch_drag=="true")) echo "selected"; ?> ><?php _e('True',wcps_textdomain);?></option>
417
+ <option value="false" <?php if(($wcps_slider_touch_drag=="false")) echo "selected"; ?> ><?php _e('False',wcps_textdomain);?></option>
418
  </select>
419
+
420
+
421
+ <p class="option-info"><?php _e('Slider Mouse Drag Enabled',wcps_textdomain);?></p>
 
 
 
422
 
423
  <select name="wcps_slider_mouse_drag">
424
+ <option value="true" <?php if(($wcps_slider_mouse_drag=="true")) echo "selected"; ?> ><?php _e('True',wcps_textdomain);?></option>
425
+ <option value="false" <?php if(($wcps_slider_mouse_drag=="false")) echo "selected"; ?> ><?php _e('False',wcps_textdomain);?></option>
426
  </select>
427
+
428
+
429
+
430
+
431
+
432
+
433
+
434
+ </div>
435
+
436
+
437
 
438
+
439
+
440
+
441
+
442
+
443
+
444
 
445
  </li>
446
  <li style="display: none;" class="box3 tab-box ">
447
  <div class="option-box">
448
+ <p class="option-title"><?php _e('Themes for slider',wcps_textdomain);?></p>
449
  <p class="option-info"></p>
450
  <select name="wcps_themes" >
451
  <?php
468
 
469
 
470
  <div class="option-box">
471
+ <p class="option-title"><?php _e('Slider ribbon',wcps_textdomain);?></p>
472
  <p class="option-info"></p>
473
  <?php
474
 
515
 
516
  ?>
517
 
518
+ <input type="text" id="wcps_ribbon_custom" name="wcps_ribbon_custom" placeholder="Custom url for ribbons." id="wcps_ribbon_custom" value="<?php echo $wcps_ribbon_custom; ?>" />
519
 
520
  <?php
521
 
539
 
540
 
541
  <div class="option-box">
542
+ <p class="option-title"><?php _e('Container options',wcps_textdomain); ?></p>
543
+ <p class="option-info"><?php _e('Padding: (ex: 10px)',wcps_textdomain); ?></p>
544
  <input type="text" placeholder="10px" name="wcps_container_padding" value="<?php echo $wcps_container_padding; ?>" />
545
 
546
+ <p class="option-info"><?php _e('Background color:',wcps_textdomain); ?></p>
547
  <input type="text" class="wcps_color" name="wcps_container_bg_color" value="<?php echo $wcps_container_bg_color; ?>" />
548
 
549
+ <p class="option-info"><?php _e('Background image:',wcps_textdomain); ?></p>
550
  <img class="bg_image_src" onClick="bg_img_src(this)" src="<?php echo wcps_plugin_url; ?>assets/global/images/bg/dark_embroidery.png" />
551
  <img class="bg_image_src" onClick="bg_img_src(this)" src="<?php echo wcps_plugin_url; ?>assets/global/images/bg/dimension.png" />
552
  <img class="bg_image_src" onClick="bg_img_src(this)" src="<?php echo wcps_plugin_url; ?>assets/global/images/bg/eight_horns.png" />
553
  <br />
554
+ <input type="text" id="wcps_bg_img" class="wcps_bg_img" name="wcps_bg_img" value="<?php echo $wcps_bg_img; ?>" /> <div onClick="clear_container_bg_image()" class="button clear-container-bg-image"> <?php _e('Clear',wcps_textdomain); ?></div>
555
 
556
  <script>
557
 
576
 
577
 
578
  <div class="option-box">
579
+ <p class="option-title"><?php _e('Items Options',wcps_textdomain); ?></p>
580
+ <p class="option-info"><?php _e('Items background color',wcps_textdomain); ?></p>
581
  <input type="text" class="wcps_color" name="wcps_items_bg_color" value="<?php echo $wcps_items_bg_color; ?>" />
582
 
583
+ <p class="option-info"><?php _e('Items padding',wcps_textdomain); ?></p>
584
  <input type="text" name="wcps_items_padding" placeholder="5px" value="<?php echo $wcps_items_padding; ?>" />
585
 
586
  </div>
590
 
591
  </li>
592
  <li style="display: none;" class="box4 tab-box ">
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
593
 
594
+ <div class="option-box">
595
+ <p class="option-title"><?php _e('Total Number of Product', wcps_textdomain);?></p>
596
+ <p class="option-info"><?php _e('ex: 10, to display all product please use -1', wcps_textdomain);?></p>
597
+ <input type="text" placeholder="10" name="wcps_total_items" value="<?php echo $wcps_total_items; ?>" />
598
+ </div>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
599
 
600
  <div class="option-box">
601
+ <p class="option-title"><?php _e('Query order', wcps_textdomain); ?></p>
602
  <p class="option-info"></p>
603
  <select name="wcps_query_order" >
604
+ <option value="DESC" <?php if($wcps_query_order=="DESC") echo "selected"; ?>><?php _e('Descending',wcps_textdomain);?></option>
605
+ <option value="ASC" <?php if($wcps_query_order=="ASC") echo "selected"; ?>><?php _e('Ascending ',wcps_textdomain);?></option>
 
606
 
607
  </select>
608
  </div>
613
 
614
 
615
  <div class="option-box">
616
+ <p class="option-title"><?php _e('Query orderBy',wcps_textdomain); ?></p>
617
  <p class="option-info"></p>
618
  <select name="wcps_query_orderby" >
619
+ <option value="none" <?php if($wcps_query_orderby=="none") echo "selected"; ?>><?php _e('None',wcps_textdomain);?></option>
620
+ <option value="ID" <?php if($wcps_query_orderby=="ID") echo "selected"; ?>><?php _e('ID',wcps_textdomain);?></option>
621
+ <option value="date" <?php if($wcps_query_orderby=="date") echo "selected"; ?>><?php _e('Date',wcps_textdomain);?></option>
622
+ <option value="rand" <?php if($wcps_query_orderby=="rand") echo "selected"; ?>><?php _e('Rand',wcps_textdomain);?></option>
623
+ <option value="comment_count" <?php if($wcps_query_orderby=="comment_count") echo "selected"; ?>><?php _e('Comment Count',wcps_textdomain);?></option>
624
+ <option value="author" <?php if($wcps_query_orderby=="author") echo "selected"; ?>><?php _e('Author',wcps_textdomain);?></option>
625
+ <option value="title" <?php if($wcps_query_orderby=="title") echo "selected"; ?>><?php _e('Title',wcps_textdomain);?></option>
626
+ <option value="name" <?php if($wcps_query_orderby=="name") echo "selected"; ?>><?php _e('Name',wcps_textdomain);?></option>
627
+ <option value="type" <?php if($wcps_query_orderby=="type") echo "selected"; ?>><?php _e('Type',wcps_textdomain);?></option>
628
 
629
 
630
  </select>
631
  </div>
632
 
633
+
634
  <div class="option-box">
635
+
636
+ <p class="option-info"><?php _e('Hide out of stock items',wcps_textdomain); ?></p>
637
+ <label><input <?php if($wcps_hide_out_of_stock=="yes") echo "checked";?> type="radio" name="wcps_hide_out_of_stock" value="yes" />Yes</label>
638
+ <label><input <?php if($wcps_hide_out_of_stock=="no") echo "checked";?> type="radio" name="wcps_hide_out_of_stock" value="no" />No</label>
 
 
639
 
640
+ <p class="option-info"><?php _e('Featured Product display', wcps_textdomain);?></p>
641
+ <label><input <?php if($wcps_product_featured=="yes") echo "checked";?> type="radio" name="wcps_product_featured" value="yes" />Yes</label>
642
+ <label><input <?php if($wcps_product_featured=="no") echo "checked";?> type="radio" name="wcps_product_featured" value="no" />No</label>
643
+
644
+ <p class="option-info"><?php _e('On Sale Product display', wcps_textdomain);?></p>
645
+ <label><input <?php if($wcps_product_on_sale=="yes") echo "checked";?> type="radio" name="wcps_product_on_sale" value="yes" />Yes</label>
646
+ <label><input <?php if($wcps_product_on_sale=="no") echo "checked";?> type="radio" name="wcps_product_on_sale" value="no" />No</label>
647
+
648
+
649
+
650
+ </div>
651
+
652
+
653
 
654
 
655
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
656
 
657
+
658
+
659
+
660
+
661
+
662
+
663
 
664
+
 
 
665
 
666
+ </li>
667
+ <li style="display: none;" class="box5 tab-box">
668
+
669
+ <div class="option-box">
670
+ <p class="option-title"><?php _e('Slider items.', wcps_textdomain); ?></p>
671
+ <p class="option-info"></p>
672
+ <div class="button wcps_grid_items_reset" wcps_id="<?php echo $wcps_id; ?>"><?php _e('Reset', wcps_textdomain);?></div>
673
  <br /><br />
674
 
675
  <?php
698
 
699
 
700
  foreach($wcps_grid_items as $item_key=>$item_name){
701
+
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
702
 
703
+ ?>
704
+ <div class="item">
705
+ <div class="header">
706
+ <span class="move"><i class="fa fa-bars"></i></span>
707
+ <span class="expand"><i class="fa fa-expand"></i><i class="fa fa-compress"></i></span>
708
+ <span class="name"><?php echo $item_name; ?></span>
709
+ <input type="hidden" name="wcps_grid_items[<?php echo $item_key; ?>]" value="<?php echo $item_name; ?>" />
710
+ <?php
711
+
712
+ if(!empty($wcps_grid_items_hide[$item_key])){
713
+
714
+ $checked = 'checked';
715
+ }
716
+ else{
717
+ $checked = '';
718
+ }
719
+
720
+ ?>
721
+ <label><input <?php echo $checked; ?> type="checkbox" class="wcps_grid_items_hide" name="wcps_grid_items_hide[<?php echo $item_key; ?>]" value="1" />Hide on front-end</label>
722
+
723
+ </div> <!-- .header -->
724
+ <div class="options">
725
+ <?php
726
+
727
  if($item_key == 'thumb'){
728
 
729
  ?>
730
  <div class="option-box">
731
+ <p class="option-title"><?php _e('Slider Thumbnail Size', wcps_textdomain);?></p>
732
  <p class="option-info"></p>
733
+
734
+ <?php
735
+
736
+ $get_intermediate_image_sizes = get_intermediate_image_sizes();
737
+
738
+ $get_intermediate_image_sizes = array_merge($get_intermediate_image_sizes,array('full'));
739
+
740
+
741
+ //echo '<pre>'.var_export($get_intermediate_image_sizes, true).'</pre>';
742
+
743
+ ?>
744
+
745
+
746
  <select name="wcps_items_thumb_size" >
747
+
748
+
749
+ <?php
750
+
751
+
752
+
753
+ foreach($get_intermediate_image_sizes as $size_key){
754
+
755
+ ?>
756
+ <option value="<?php echo $size_key; ?>" <?php if($wcps_items_thumb_size==$size_key)echo "selected"; ?>>
757
+
758
+
759
+ <?php
760
+
761
+ $size_key = str_replace('_', ' ',$size_key);
762
+ $size_key = str_replace('-', ' ',$size_key);
763
+ $size_key = ucfirst($size_key);
764
+
765
+ echo $size_key;
766
+
767
+ ?>
768
+
769
+ </option>
770
+
771
+
772
+
773
+ <?php
774
+
775
+
776
+ }
777
+
778
+
779
+
780
+
781
+ ?>
782
+
783
+
784
+
785
+
786
+
787
+
788
 
789
  </select>
790
  </div>
791
 
792
 
793
  <div class="option-box">
794
+ <p class="option-title"><?php _e('Items thumbnail link\'s to', wcps_textdomain);?></p>
795
  <p class="option-info"></p>
796
  <select name="wcps_items_thumb_link_to" >
797
+ <option value="product" <?php if($wcps_items_thumb_link_to=="product")echo "selected"; ?>><?php _e('Product', wcps_textdomain);?></option>
798
+ <option value="category" <?php if($wcps_items_thumb_link_to=="category")echo "selected"; ?>><?php _e('Category', wcps_textdomain);?></option>
799
  </select>
800
  </div>
801
 
803
 
804
 
805
  <div class="option-box">
806
+ <p class="option-title"><?php _e('Slider thumb max hieght(px)', wcps_textdomain);?></p>
807
  <p class="option-info"></p>
808
  <input type="text" name="wcps_items_thumb_max_hieght" placeholder="14px" id="wcps_items_thumb_max_hieght" value="<?php echo $wcps_items_thumb_max_hieght; ?>" />
809
  </div>
810
 
811
  <div class="option-box">
812
+ <p class="option-title"><?php _e('Display Thumbnail Zoom button', wcps_textdomain);?></p>
813
  <p class="option-info"></p>
814
  <select name="wcps_items_thumb_zoom" >
815
+ <option value="no" <?php if($wcps_items_thumb_zoom=="no")echo "selected"; ?>><?php _e('No', wcps_textdomain);?></option>
816
+ <option value="yes" <?php if($wcps_items_thumb_zoom=="yes")echo "selected"; ?>><?php _e('Yes', wcps_textdomain);?></option>
817
 
818
  </select>
819
  </div>
820
 
821
 
822
+ <div class="option-box">
823
+ <p class="option-title"><?php _e('Empty Thumbnail', wcps_textdomain);?></p>
824
+ <p class="option-info"><?php _e('Custom thumbnail image url', wcps_textdomain);?></p>
825
+ <input type="text" name="wcps_items_empty_thumb" id="wcps_items_empty_thumb" value="<?php echo $wcps_items_empty_thumb; ?>" /><br /><br />
826
+ <input id="wcps_items_empty_thumb_upload" class="wcps_items_empty_thumb_upload button" type="button" value="Upload Image" />
827
+ <br /><br />
828
+
829
+
830
+ <?php
831
+ if(empty($wcps_items_empty_thumb))
832
+ {
833
+ ?>
834
+ <img class="wcps_items_empty_thumb_display" width="300px" src="<?php echo wcps_plugin_url.'assets/front/images/no-thumb.png'; ?>" />
835
+ <?php
836
+ }
837
+ else
838
+ {
839
+ ?>
840
+ <img class="wcps_items_empty_thumb_display" width="300px" src="<?php echo $wcps_items_empty_thumb; ?>" />
841
+ <?php
842
+ }
843
+ ?>
844
+
845
+
846
+
847
+
848
+
849
+ <script>
850
+ jQuery(document).ready(function($){
851
+
852
+ var custom_uploader;
853
+
854
+ jQuery('#wcps_items_empty_thumb_upload').click(function(e) {
855
+
856
+ e.preventDefault();
857
+
858
+ //If the uploader object has already been created, reopen the dialog
859
+ if (custom_uploader) {
860
+ custom_uploader.open();
861
+ return;
862
+ }
863
+
864
+ //Extend the wp.media object
865
+ custom_uploader = wp.media.frames.file_frame = wp.media({
866
+ title: 'Choose Image',
867
+ button: {
868
+ text: 'Choose Image'
869
+ },
870
+ multiple: false
871
+ });
872
+
873
+ //When a file is selected, grab the URL and set it as the text field's value
874
+ custom_uploader.on('select', function() {
875
+ attachment = custom_uploader.state().get('selection').first().toJSON();
876
+ jQuery('#wcps_items_empty_thumb').val(attachment.url);
877
+ jQuery('.wcps_items_empty_thumb_display').attr('src',attachment.url);
878
+ });
879
+
880
+ //Open the uploader dialog
881
+ custom_uploader.open();
882
+
883
+ });
884
+
885
+
886
+ })
887
+ </script>
888
+ </div>
889
+
890
+
891
+
892
+
893
  <?php
894
 
895
  }
897
 
898
  ?>
899
  <div class="option-box">
900
+ <p class="option-title"><?php _e('Items add to cart button Style', wcps_textdomain);?></p>
901
+ <p class="option-info"><?php _e('You can hide items add to cart button on slider.', wcps_textdomain);?></p>
902
  <select name="wcps_cart_style" >
903
+ <option value="default" <?php if($wcps_cart_style=="default")echo "selected"; ?>><?php _e('Default', wcps_textdomain);?></option>
904
+ <option value="custom" <?php if($wcps_cart_style=="custom")echo "selected"; ?>><?php _e('Custom', wcps_textdomain);?></option>
905
  </select>
906
  </div>
907
 
908
  <div class="option-box">
909
+ <p class="option-title"><?php _e('Add to cart background color', wcps_textdomain);?></p>
910
  <p class="option-info"></p>
911
  <input type="text" name="wcps_cart_bg" class="wcps_color" id="wcps_cart_bg" value="<?php echo $wcps_cart_bg; ?>" />
912
  </div>
913
 
914
  <div class="option-box">
915
+ <p class="option-title"><?php _e('Add to cart text color', wcps_textdomain);?></p>
916
  <p class="option-info"></p>
917
  <input type="text" name="wcps_cart_text_color" class="wcps_color" id="wcps_cart_text_color" value="<?php echo $wcps_cart_text_color; ?>" />
918
  </div>
919
 
920
  <div class="option-box">
921
+ <p class="option-title"><?php _e('Items cart text align', wcps_textdomain);?></p>
922
 
923
 
924
  <select name="wcps_cart_text_align" >
925
+ <option value="left" <?php if($wcps_cart_text_align=="left")echo "selected"; ?>><?php _e('Left', wcps_textdomain);?></option>
926
+ <option value="right" <?php if($wcps_cart_text_align=="right")echo "selected"; ?>><?php _e('Right', wcps_textdomain);?></option>
927
+ <option value="center" <?php if($wcps_cart_text_align=="center")echo "selected"; ?>><?php _e('Center', wcps_textdomain);?></option>
928
  </select>
929
 
930
  </div>
940
 
941
 
942
  <div class="option-box">
943
+ <p class="option-title"><?php _e('Sale marker icon url', wcps_textdomain);?></p>
944
  <p class="option-info"></p>
945
  <input type="text" name="wcps_sale_icon_url" placeholder="" id="wcps_sale_icon_url" value="<?php echo $wcps_sale_icon_url; ?>" />
946
  </div>
959
 
960
 
961
  <div class="option-box">
962
+ <p class="option-title"><?php _e('Items Title Color', wcps_textdomain);?></p>
963
  <p class="option-info"></p>
964
  <input type="text" name="wcps_items_title_color" class="wcps_color" id="wcps_items_title_color" value="<?php echo $wcps_items_title_color; ?>" />
965
  </div>
966
  <div class="option-box">
967
+ <p class="option-title"><?php _e('Items Title Font Size', wcps_textdomain);?></p>
968
  <p class="option-info"></p>
969
  <input type="text" name="wcps_items_title_font_size" placeholder="14px" id="wcps_items_title_font_size" value="<?php echo $wcps_items_title_font_size; ?>" />
970
  </div>
971