CTX Feed – WooCommerce Product Feed Manager Plugin - Version 3.0.39

Version Description

Download this release

Release Info

Developer wahid0003
Plugin Icon 128x128 CTX Feed – WooCommerce Product Feed Manager Plugin
Version 3.0.39
Comparing to
See all releases

Code changes from version 3.0.38 to 3.0.39

README.txt CHANGED
@@ -4,7 +4,7 @@ Donate link: https://webappick.com
4
  Tags:woocommerce,google product feed,facebook product feed,woocommerce product feed,woocommerce,
5
  Requires at least: 3.6
6
  Tested Up To: 5.2
7
- Stable tag: 3.0.38
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -303,6 +303,10 @@ Using pro version:
303
 
304
  == Changelog ==
305
 
 
 
 
 
306
  = 3.0.38(2019-06-18) =
307
  * Added: Vergelijk.be & Comparer.be template added
308
 
4
  Tags:woocommerce,google product feed,facebook product feed,woocommerce product feed,woocommerce,
5
  Requires at least: 3.6
6
  Tested Up To: 5.2
7
+ Stable tag: 3.0.39
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
303
 
304
  == Changelog ==
305
 
306
+ = 3.0.39(2019-06-20) =
307
+ * Fixed: Prefix & suffix with empty value and stripslash issue fixed
308
+ * Added: Override attribute added for facebook template
309
+
310
  = 3.0.38(2019-06-18) =
311
  * Added: Vergelijk.be & Comparer.be template added
312
 
admin/partials/templates/custom_edit-feed.php CHANGED
@@ -180,7 +180,7 @@ if(!isset($feedRules['ftporsftp'])){
180
  class="wf_mattributes"/>
181
  </td>
182
  <td>
183
- <input type="text" name="prefix[]" value="<?php echo esc_html($prefix[$merchant]); ?>"
184
  autocomplete="off"
185
  class="wf_ps"/>
186
  </td>
@@ -205,11 +205,11 @@ if(!isset($feedRules['ftporsftp'])){
205
  <input <?php echo ($type[$merchant] == "pattern") ? '' : 'style=" display: none;"'; ?>
206
  autocomplete="off"
207
  class="wf_default wf_attributes" type="text" name="default[]"
208
- value="<?php echo esc_attr($default[$merchant]); ?>"/>
209
 
210
  </td>
211
  <td>
212
- <input type="text" name="suffix[]" value="<?php echo esc_html($suffix[$merchant]); ?>"
213
  autocomplete="off"
214
  class="wf_ps"/>
215
  </td>
180
  class="wf_mattributes"/>
181
  </td>
182
  <td>
183
+ <input type="text" name="prefix[]" value="<?php echo stripslashes($prefix[$merchant]); ?>"
184
  autocomplete="off"
185
  class="wf_ps"/>
186
  </td>
205
  <input <?php echo ($type[$merchant] == "pattern") ? '' : 'style=" display: none;"'; ?>
206
  autocomplete="off"
207
  class="wf_default wf_attributes" type="text" name="default[]"
208
+ value="<?php echo stripslashes($default[$merchant]); ?>"/>
209
 
210
  </td>
211
  <td>
212
+ <input type="text" name="suffix[]" value="<?php echo stripslashes($suffix[$merchant]); ?>"
213
  autocomplete="off"
214
  class="wf_ps"/>
215
  </td>
admin/partials/woo-feed-admin-display.php CHANGED
@@ -16,7 +16,8 @@ $dropDown = new Woo_Feed_Dropdown();
16
  $product = new Woo_Feed_Products();
17
  $attributes=new Woo_Feed_Default_Attributes();
18
  $product->load_attributes();
19
-
 
20
  ?>
21
 
22
  <div class="wrap" id="Feed">
16
  $product = new Woo_Feed_Products();
17
  $attributes=new Woo_Feed_Default_Attributes();
18
  $product->load_attributes();
19
+ echo stripslashes("ABC\'s Co.");
20
+ die();
21
  ?>
22
 
23
  <div class="wrap" id="Feed">
admin/partials/woo-feed-edit-template.php CHANGED
@@ -189,7 +189,7 @@ $AttributesDropdown = $feedRules['provider'] . "AttributesDropdown";
189
  </select>
190
  </td>
191
  <td>
192
- <input type="text" name="prefix[]" value="<?php echo esc_attr($prefix[$merchant]); ?>"
193
  autocomplete="off"
194
  class="wf_ps"/>
195
  </td>
@@ -226,13 +226,13 @@ $AttributesDropdown = $feedRules['provider'] . "AttributesDropdown";
226
  <input <?php echo ($type[$merchant] == "pattern") ? '' : 'style=" display: none;"'; ?>
227
  autocomplete="off"
228
  class="wf_default wf_attributes " type="text" name="default[]"
229
- value="<?php echo esc_attr($default[$merchant]); ?>"/>
230
  <?php
231
  }
232
  ?>
233
  </td>
234
  <td>
235
- <input type="text" name="suffix[]" value="<?php echo esc_attr($suffix[$merchant]); ?>"
236
  autocomplete="off"
237
  class="wf_ps"/>
238
  </td>
189
  </select>
190
  </td>
191
  <td>
192
+ <input type="text" name="prefix[]" value="<?php echo stripslashes($prefix[$merchant]); ?>"
193
  autocomplete="off"
194
  class="wf_ps"/>
195
  </td>
226
  <input <?php echo ($type[$merchant] == "pattern") ? '' : 'style=" display: none;"'; ?>
227
  autocomplete="off"
228
  class="wf_default wf_attributes " type="text" name="default[]"
229
+ value="<?php echo stripslashes($default[$merchant]); ?>"/>
230
  <?php
231
  }
232
  ?>
233
  </td>
234
  <td>
235
+ <input type="text" name="suffix[]" value="<?php echo stripslashes($suffix[$merchant]); ?>"
236
  autocomplete="off"
237
  class="wf_ps"/>
238
  </td>
includes/class-woo-feed.php CHANGED
@@ -70,7 +70,7 @@ class Woo_Feed
70
  public function __construct()
71
  {
72
  $this->woo_feed = 'woo-feed';
73
- $this->version = '3.0.38';
74
  $this->load_dependencies();
75
  $this->set_locale();
76
  $this->define_admin_hooks();
70
  public function __construct()
71
  {
72
  $this->woo_feed = 'woo-feed';
73
+ $this->version = '3.0.39';
74
  $this->load_dependencies();
75
  $this->set_locale();
76
  $this->define_admin_hooks();
includes/classes/class-woo-feed-default-attributes.php CHANGED
@@ -3822,6 +3822,7 @@ class Woo_Feed_Default_Attributes
3822
  "cost_of_goods_sold" => "Cost of Goods Sold[cost_of_goods_sold]",
3823
  "expiration_date" => "Expiration Date[expiration_date]",
3824
  "inventory" => "Facebook Inventory[inventory]",
 
3825
  "price" => "Regular Price[price]",
3826
  "sale_price" => "Sale Price[sale_price]",
3827
  "sale_price_effective_date" => "Sale Price Effective Date[sale_price_effective_date]",
3822
  "cost_of_goods_sold" => "Cost of Goods Sold[cost_of_goods_sold]",
3823
  "expiration_date" => "Expiration Date[expiration_date]",
3824
  "inventory" => "Facebook Inventory[inventory]",
3825
+ "override" => "Facebook Override[override]",
3826
  "price" => "Regular Price[price]",
3827
  "sale_price" => "Sale Price[sale_price]",
3828
  "sale_price_effective_date" => "Sale Price Effective Date[sale_price_effective_date]",
includes/classes/class-woo-feed-engine.php CHANGED
@@ -223,11 +223,14 @@ class WF_Engine
223
  if(substr($output, 0, 4 ) === "http"){
224
  $output = $this->make_url_with_parameter($rules['prefix'],$output,$rules['suffix']);
225
  }else{
226
- if($attr=='price'){
227
  $suffix=!empty($rules['suffix'])?trim($rules['suffix']):$rules['suffix'];
228
  $output = $rules['prefix'].$output." ".$suffix;
229
  }else{
230
- $output = $rules['prefix'].$output.$rules['suffix'];
 
 
 
231
  }
232
  }
233
  $output = '<![CDATA[' . $output . ']]>';
@@ -235,11 +238,14 @@ class WF_Engine
235
  if(substr($output, 0, 4 ) === "http"){
236
  $output = $this->make_url_with_parameter($rules['prefix'],$output,$rules['suffix']);
237
  }else{
238
- if($attr=='price'){
239
  $suffix=!empty($rules['suffix'])?trim($rules['suffix']):$rules['suffix'];
240
  $output = $rules['prefix'].$output." ".$suffix;
241
  }else{
242
- $output = $rules['prefix'].$output.$rules['suffix'];
 
 
 
243
  }
244
  }
245
  }
@@ -305,11 +311,14 @@ class WF_Engine
305
  if(substr($output, 0, 4 ) === "http"){
306
  $output = $this->make_url_with_parameter($rules['prefix'],$output,$rules['suffix']);
307
  }else{
308
- if($attr=='price'){
309
  $suffix=!empty($rules['suffix'])?trim($rules['suffix']):$rules['suffix'];
310
  $output = $rules['prefix'].$output." ".$suffix;
311
  }else{
312
- $output = $rules['prefix'].$output.$rules['suffix'];
 
 
 
313
  }
314
  }
315
  $output = '<![CDATA[' . $output . ']]>';
@@ -318,11 +327,14 @@ class WF_Engine
318
  if(substr($output, 0, 4 ) === "http"){
319
  $output = $this->make_url_with_parameter($rules['prefix'],$output,$rules['suffix']);
320
  }else{
321
- if($attr=='price'){
322
  $suffix=!empty($rules['suffix'])?trim($rules['suffix']):$rules['suffix'];
323
  $output = $rules['prefix'].$output." ".$suffix;
324
  }else{
325
- $output = $rules['prefix'].$output.$rules['suffix'];
 
 
 
326
  }
327
  }
328
  }
@@ -341,6 +353,9 @@ class WF_Engine
341
  $this->products[$key][$attr] = $output;
342
  } else {
343
  $output = str_replace("wf_pattern_", "", $rules['value']);
 
 
 
344
  if ($output=="0"){
345
  $output="0";
346
  } else{
@@ -383,12 +398,15 @@ class WF_Engine
383
  }
384
 
385
  $params=array_merge($URLParam,$EXTRAParam);
386
- if(!empty($params)){
387
  $params=http_build_query($params);
388
  $baseURL=isset($getParam)?$getParam[0]:$output;
389
  $output = $prefix.$baseURL."?".$params;
390
  }else{
391
- $output = $prefix.$output.$suffix;
 
 
 
392
  }
393
 
394
  return $output;
223
  if(substr($output, 0, 4 ) === "http"){
224
  $output = $this->make_url_with_parameter($rules['prefix'],$output,$rules['suffix']);
225
  }else{
226
+ if($attr=='price' || $output != ""){
227
  $suffix=!empty($rules['suffix'])?trim($rules['suffix']):$rules['suffix'];
228
  $output = $rules['prefix'].$output." ".$suffix;
229
  }else{
230
+ if($output != "")
231
+ {
232
+ $output = $rules['prefix'].$output.$rules['suffix'];
233
+ }
234
  }
235
  }
236
  $output = '<![CDATA[' . $output . ']]>';
238
  if(substr($output, 0, 4 ) === "http"){
239
  $output = $this->make_url_with_parameter($rules['prefix'],$output,$rules['suffix']);
240
  }else{
241
+ if($attr=='price' && $output != ""){
242
  $suffix=!empty($rules['suffix'])?trim($rules['suffix']):$rules['suffix'];
243
  $output = $rules['prefix'].$output." ".$suffix;
244
  }else{
245
+ if($output != "")
246
+ {
247
+ $output = $rules['prefix'].$output.$rules['suffix'];
248
+ }
249
  }
250
  }
251
  }
311
  if(substr($output, 0, 4 ) === "http"){
312
  $output = $this->make_url_with_parameter($rules['prefix'],$output,$rules['suffix']);
313
  }else{
314
+ if($attr=='price' && $output != ""){
315
  $suffix=!empty($rules['suffix'])?trim($rules['suffix']):$rules['suffix'];
316
  $output = $rules['prefix'].$output." ".$suffix;
317
  }else{
318
+ if($output != "")
319
+ {
320
+ $output = $rules['prefix'].$output.$rules['suffix'];
321
+ }
322
  }
323
  }
324
  $output = '<![CDATA[' . $output . ']]>';
327
  if(substr($output, 0, 4 ) === "http"){
328
  $output = $this->make_url_with_parameter($rules['prefix'],$output,$rules['suffix']);
329
  }else{
330
+ if($attr=='price' && $output != ""){
331
  $suffix=!empty($rules['suffix'])?trim($rules['suffix']):$rules['suffix'];
332
  $output = $rules['prefix'].$output." ".$suffix;
333
  }else{
334
+ if($output != "")
335
+ {
336
+ $output = $rules['prefix'].$output.$rules['suffix'];
337
+ }
338
  }
339
  }
340
  }
353
  $this->products[$key][$attr] = $output;
354
  } else {
355
  $output = str_replace("wf_pattern_", "", $rules['value']);
356
+ if(!empty($output)){
357
+ $output=stripslashes($output);
358
+ }
359
  if ($output=="0"){
360
  $output="0";
361
  } else{
398
  }
399
 
400
  $params=array_merge($URLParam,$EXTRAParam);
401
+ if(!empty($params) && $output != ""){
402
  $params=http_build_query($params);
403
  $baseURL=isset($getParam)?$getParam[0]:$output;
404
  $output = $prefix.$baseURL."?".$params;
405
  }else{
406
+ if($output != "")
407
+ {
408
+ $output = $prefix.$output.$suffix;
409
+ }
410
  }
411
 
412
  return $output;
includes/feeds/class-woo-feed-facebook.php CHANGED
@@ -170,6 +170,7 @@ class Woo_Feed_Facebook
170
  "condition" => array("g:condition", false),
171
  "availability" => array("g:availability", false),
172
  "inventory" => array("g:inventory", false),
 
173
  "price" => array("g:price", true),
174
  "sale_price" => array("g:sale_price", true),
175
  "sale_price_effective_date" => array("g:sale_price_effective_date", true),
@@ -258,6 +259,7 @@ class Woo_Feed_Facebook
258
  "condition" => array("condition", false),
259
  "availability" => array("availability", false),
260
  "inventory" => array("inventory", false),
 
261
  "price" => array("price", true),
262
  "sale_price" => array("sale price", true),
263
  "sale_price_effective_date" => array("sale price effective date", true),
170
  "condition" => array("g:condition", false),
171
  "availability" => array("g:availability", false),
172
  "inventory" => array("g:inventory", false),
173
+ "override" => array("g:override", false),
174
  "price" => array("g:price", true),
175
  "sale_price" => array("g:sale_price", true),
176
  "sale_price_effective_date" => array("g:sale_price_effective_date", true),
259
  "condition" => array("condition", false),
260
  "availability" => array("availability", false),
261
  "inventory" => array("inventory", false),
262
+ "override" => array("override", false),
263
  "price" => array("price", true),
264
  "sale_price" => array("sale price", true),
265
  "sale_price_effective_date" => array("sale price effective date", true),
woo-feed.php CHANGED
@@ -16,7 +16,7 @@
16
  * Plugin Name: WooCommerce Product Feed
17
  * Plugin URI: https://webappick.com/
18
  * Description: This plugin generate WooCommerce product feed for Shopping Engines like Google Shopping,Facebook Product Feed,eBay,Amazon,Idealo and many more..
19
- * Version: 3.0.38
20
  * Author: WebAppick
21
  * Author URI: https://webappick.com/
22
  * License: GPL v2
16
  * Plugin Name: WooCommerce Product Feed
17
  * Plugin URI: https://webappick.com/
18
  * Description: This plugin generate WooCommerce product feed for Shopping Engines like Google Shopping,Facebook Product Feed,eBay,Amazon,Idealo and many more..
19
+ * Version: 3.0.39
20
  * Author: WebAppick
21
  * Author URI: https://webappick.com/
22
  * License: GPL v2