Product Import Export for WooCommerce - Version 1.0.2

Version Description

  • Bug Fix: Improved parsing while importing product price with currency symbol and thousand separator.
Download this release

Release Info

Developer hikeforce
Plugin Icon 128x128 Product Import Export for WooCommerce
Version 1.0.2
Comparing to
See all releases

Code changes from version 1.0.1 to 1.0.2

includes/importer/class-wf-csv-parser.php CHANGED
@@ -322,15 +322,19 @@ class WF_CSV_Parser {
322
if ( $merging ) {
323
if ( ! isset( $postmeta['regular_price'] ) )
324
$postmeta['regular_price'] = get_post_meta( $post_id, '_regular_price', true );
325
if ( ! isset( $postmeta['sale_price'] ) )
326
$postmeta['sale_price'] = get_post_meta( $post_id, '_sale_price', true );
327
}
328
329
if ( isset( $postmeta['regular_price'] ) && isset( $postmeta['sale_price'] ) && $postmeta['sale_price'] !== '' ) {
330
$price = min( $postmeta['sale_price'], $postmeta['regular_price']);
331
$postmeta['price'] = $price;
332
} elseif ( isset( $postmeta['regular_price'] ) ) {
333
- $postmeta['price'] = $postmeta['regular_price'];
334
}
335
336
} else {
@@ -339,15 +343,19 @@ class WF_CSV_Parser {
339
if ( $merging ) {
340
if ( ! isset( $postmeta['regular_price'] ) )
341
$postmeta['regular_price'] = get_post_meta( $post_id, '_regular_price', true );
342
if ( ! isset( $postmeta['sale_price'] ) )
343
$postmeta['sale_price'] = get_post_meta( $post_id, '_sale_price', true );
344
}
345
346
if ( isset( $postmeta['regular_price'] ) && isset( $postmeta['sale_price'] ) && $postmeta['sale_price'] !== '' ) {
347
$price = min( $postmeta['sale_price'], $postmeta['regular_price']);
348
$postmeta['price'] = $price;
349
} elseif ( isset( $postmeta['regular_price'] ) ) {
350
- $postmeta['price'] = $postmeta['regular_price'];
351
}
352
353
// Reset dynamically generated meta
@@ -876,4 +884,8 @@ class WF_CSV_Parser {
876
unset( $item, $terms_array, $postmeta, $attributes, $gpf_data, $images );
877
return $product;
878
}
879
}
322
if ( $merging ) {
323
if ( ! isset( $postmeta['regular_price'] ) )
324
$postmeta['regular_price'] = get_post_meta( $post_id, '_regular_price', true );
325
+ $postmeta['regular_price'] = $this->hf_currency_formatter($postmeta['regular_price']);
326
if ( ! isset( $postmeta['sale_price'] ) )
327
$postmeta['sale_price'] = get_post_meta( $post_id, '_sale_price', true );
328
+ $postmeta['sale_price'] = $this->hf_currency_formatter($postmeta['sale_price']);
329
}
330
331
if ( isset( $postmeta['regular_price'] ) && isset( $postmeta['sale_price'] ) && $postmeta['sale_price'] !== '' ) {
332
+ $postmeta['sale_price'] = $this->hf_currency_formatter($postmeta['sale_price']);
333
+ $postmeta['regular_price'] = $this->hf_currency_formatter($postmeta['regular_price']);
334
$price = min( $postmeta['sale_price'], $postmeta['regular_price']);
335
$postmeta['price'] = $price;
336
} elseif ( isset( $postmeta['regular_price'] ) ) {
337
+ $postmeta['price'] = $this->hf_currency_formatter($postmeta['regular_price']);
338
}
339
340
} else {
343
if ( $merging ) {
344
if ( ! isset( $postmeta['regular_price'] ) )
345
$postmeta['regular_price'] = get_post_meta( $post_id, '_regular_price', true );
346
+ $postmeta['regular_price'] = $this->hf_currency_formatter($postmeta['regular_price']);
347
if ( ! isset( $postmeta['sale_price'] ) )
348
$postmeta['sale_price'] = get_post_meta( $post_id, '_sale_price', true );
349
+ $postmeta['sale_price'] = $this->hf_currency_formatter($postmeta['sale_price']);
350
}
351
352
if ( isset( $postmeta['regular_price'] ) && isset( $postmeta['sale_price'] ) && $postmeta['sale_price'] !== '' ) {
353
+ $postmeta['sale_price'] = $this->hf_currency_formatter($postmeta['sale_price']);
354
+ $postmeta['regular_price'] = $this->hf_currency_formatter($postmeta['regular_price']);
355
$price = min( $postmeta['sale_price'], $postmeta['regular_price']);
356
$postmeta['price'] = $price;
357
} elseif ( isset( $postmeta['regular_price'] ) ) {
358
+ $postmeta['price'] = $this->hf_currency_formatter($postmeta['regular_price']);
359
}
360
361
// Reset dynamically generated meta
884
unset( $item, $terms_array, $postmeta, $attributes, $gpf_data, $images );
885
return $product;
886
}
887
+ function hf_currency_formatter($price){
888
+ $decimal_seperator = wc_get_price_decimal_separator();
889
+ return ereg_replace("[^0-9\\'.$decimal_seperator.']", "", $price);
890
+ }
891
}
product-csv-import-export.php CHANGED
@@ -5,7 +5,7 @@ Plugin URI: http://hikeforce.com/product/product-import-export-plugin-for-woocom
5
Description: Import and Export Products including Variations, From and To your WooCommerce Store.
6
Author: HikeForce
7
Author URI: http://www.hikeforce.com/
8
- Version: 1.0.1
9
Text Domain: wf_csv_import_export
10
*/
11
5
Description: Import and Export Products including Variations, From and To your WooCommerce Store.
6
Author: HikeForce
7
Author URI: http://www.hikeforce.com/
8
+ Version: 1.0.2
9
Text Domain: wf_csv_import_export
10
*/
11
readme.txt CHANGED
@@ -1,93 +1,97 @@
1
- === Product Import Export for WooCommerce===
2
- Contributors: hikeforce
3
- Donate link:
4
- Tags: woocommerce import products, woocommerce export products, woocommerce export import products, export woocommerce products with images, woocommerce csv import variable products, woocommerce import products with attributes
5
- Requires at least: 3.0.1
6
- Tested up to: Latest
7
- Stable tag: 1.0.1
8
- License: GPLv2 or later
9
- License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
-
11
- Product Import Export Plugin for WooCommerce
12
-
13
- == Description ==
14
-
15
- = Introduction =
16
-
17
- WooCommerce Product Import Export Plugin helps you to easily export and import products in your store. This plugin lets you import/export simple products. It is super simple!
18
-
19
- <ul>
20
- <li>Export Simple Products in to a CSV file.</li>
21
- <li>Import Simple Products in CSV format in to WooCommerce Store.</li>
22
- </ul>
23
-
24
-
25
- = How does it work? =
26
-
27
- The WooCommerce Product Import Export Plugin takes CSV (Comma-Separated Values) file as input. You must create a CSV file and enter the product details in a structured format as explained in the tutorial. This is to match each field of CSV file to the field of a particular product that otherwise Admin need to input manually. For example: the post_title field gets mapped to the product name and the regular_price field gets mapped to the regular price of your product. For the plugin to work correctly, you must map headers of all of the column correctly and you must ensure that all of the fields you enter must be in the correct format.
28
-
29
- You can create the CSV from scratch or you can export the product to get the format of CSV. You can use a spreadsheet program, such as Excel, or Google Spreadsheets for creating and modifying the CSV file. Save this file with extension .CSV. After entering all details about products in spreadsheet, you can import product to your online store. With this plugin, you can also export and download product details as a CSV file.
30
-
31
- = Premium version video demo =
32
- [youtube http://www.youtube.com/watch?v=UIXjwWUdqWc]
33
-
34
- <blockquote>
35
-
36
- = Premium version Features =
37
- Product Import Export Plugin for WooCommerce
38
-
39
- <ul>
40
- <li>Export Products (Simple, Group, External and Variations) in to a CSV file</li>
41
- <li>Import products (Simple, Group, External and Variations) in CSV format in to WooComemrce Store.</li>
42
- <li>Map and Transform fields</li>
43
- <li>Merge Details for existing products </li>
44
- <li>Import/Export file from/to a remote server via FTP</li>
45
- <li>Excellent Support for setting it up!</li>
46
- </ul>
47
-
48
- Please visit <a rel="nofollow" href="http://hikeforce.com/product/product-import-export-plugin-for-woocommerce/">Product Import Export Plugin for WooCommerce</a> for more details
49
-
50
- </blockquote>
51
-
52
- = About HikeForce.com =
53
-
54
- [HikeForce.com](http://www.hikeforce.com/?utm_source=wordpress&utm_medium=referral&utm_content=import-export) creates quality WordPress/WooCommerce plugins that are easy to use and customize. We are proud to have thousands of customers actively using our plugins across the globe.
55
-
56
-
57
- == Installation ==
58
-
59
- 1. Upload the plugin folder to the /wp-content/plugins/ directory.
60
- 2. Activate the plugin through the Plugins menu in WordPress.
61
- 3. Thats it � you can now configure the plugin.
62
-
63
- == Frequently Asked Questions ==
64
-
65
- = Does this plugin support of images? =
66
-
67
- Yes. You can import or export product images along with other details
68
-
69
- == Screenshots ==
70
-
71
- 1. Product Import Screen
72
-
73
- 2. Product Export Screen
74
-
75
- == Changelog ==
76
- = 1.0.1 =
77
- * Bug Fix: Fixed issue with Evaluation field with single quotes.
78
- * Bug Fix: Option to import gallery images.
79
- * Enhancement: Improved help text for Post name and Stock quantity.
80
- * Enhancement: Improved label text for Product type, category , tags and shipping class.
81
- * Enhancement: Included links to Documentation and sample CSV.
82
- = 1.0.0 =
83
- * Import /Export Woocommerce Products.
84
-
85
- == Upgrade Notice ==
86
- = 1.0.1 =
87
- * Bug Fix: Fixed issue with Evaluation field with single quotes.
88
- * Bug Fix: Option to import gallery images.
89
- * Enhancement: Improved help text for Post name and Stock quantity.
90
- * Enhancement: Improved label text for Product type, category , tags and shipping class.
91
- * Enhancement: Included links to Documentation and sample CSV.
92
- = 1.0.0 =
93
* Import /Export Woocommerce Products.
1
+ === Product Import Export for WooCommerce===
2
+ Contributors: hikeforce
3
+ Donate link:
4
+ Tags: woocommerce import products, woocommerce export products, woocommerce export import products, export woocommerce products with images, woocommerce csv import variable products, woocommerce import products with attributes
5
+ Requires at least: 3.0.1
6
+ Tested up to: Latest
7
+ Stable tag: 1.0.2
8
+ License: GPLv2 or later
9
+ License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
+
11
+ Product Import Export Plugin for WooCommerce
12
+
13
+ == Description ==
14
+
15
+ = Introduction =
16
+
17
+ WooCommerce Product Import Export Plugin helps you to easily export and import products in your store. This plugin lets you import/export simple products. It is super simple!
18
+
19
+ <ul>
20
+ <li>Export Simple Products in to a CSV file.</li>
21
+ <li>Import Simple Products in CSV format in to WooCommerce Store.</li>
22
+ </ul>
23
+
24
+
25
+ = How does it work? =
26
+
27
+ The WooCommerce Product Import Export Plugin takes CSV (Comma-Separated Values) file as input. You must create a CSV file and enter the product details in a structured format as explained in the tutorial. This is to match each field of CSV file to the field of a particular product that otherwise Admin need to input manually. For example: the post_title field gets mapped to the product name and the regular_price field gets mapped to the regular price of your product. For the plugin to work correctly, you must map headers of all of the column correctly and you must ensure that all of the fields you enter must be in the correct format.
28
+
29
+ You can create the CSV from scratch or you can export the product to get the format of CSV. You can use a spreadsheet program, such as Excel, or Google Spreadsheets for creating and modifying the CSV file. Save this file with extension .CSV. After entering all details about products in spreadsheet, you can import product to your online store. With this plugin, you can also export and download product details as a CSV file.
30
+
31
+ = Premium version video demo =
32
+ [youtube http://www.youtube.com/watch?v=UIXjwWUdqWc]
33
+
34
+ <blockquote>
35
+
36
+ = Premium version Features =
37
+ Product Import Export Plugin for WooCommerce
38
+
39
+ <ul>
40
+ <li>Export Products (Simple, Group, External and Variations) in to a CSV file</li>
41
+ <li>Import products (Simple, Group, External and Variations) in CSV format in to WooComemrce Store.</li>
42
+ <li>Map and Transform fields</li>
43
+ <li>Merge Details for existing products </li>
44
+ <li>Import/Export file from/to a remote server via FTP</li>
45
+ <li>Excellent Support for setting it up!</li>
46
+ </ul>
47
+
48
+ Please visit <a rel="nofollow" href="http://hikeforce.com/product/product-import-export-plugin-for-woocommerce/">Product Import Export Plugin for WooCommerce</a> for more details
49
+
50
+ </blockquote>
51
+
52
+ = About HikeForce.com =
53
+
54
+ [HikeForce.com](http://www.hikeforce.com/?utm_source=wordpress&utm_medium=referral&utm_content=import-export) creates quality WordPress/WooCommerce plugins that are easy to use and customize. We are proud to have thousands of customers actively using our plugins across the globe.
55
+
56
+
57
+ == Installation ==
58
+
59
+ 1. Upload the plugin folder to the /wp-content/plugins/ directory.
60
+ 2. Activate the plugin through the Plugins menu in WordPress.
61
+ 3. Thats it � you can now configure the plugin.
62
+
63
+ == Frequently Asked Questions ==
64
+
65
+ = Does this plugin support of images? =
66
+
67
+ Yes. You can import or export product images along with other details
68
+
69
+ == Screenshots ==
70
+
71
+ 1. Product Import Screen
72
+
73
+ 2. Product Export Screen
74
+
75
+ == Changelog ==
76
+ = 1.0.2 =
77
+ * Bug Fix: Improved parsing while importing product price with currency symbol and thousand separator.
78
+ = 1.0.1 =
79
+ * Bug Fix: Fixed issue with Evaluation field with single quotes.
80
+ * Bug Fix: Option to import gallery images.
81
+ * Enhancement: Improved help text for Post name and Stock quantity.
82
+ * Enhancement: Improved label text for Product type, category , tags and shipping class.
83
+ * Enhancement: Included links to Documentation and sample CSV.
84
+ = 1.0.0 =
85
+ * Import /Export Woocommerce Products.
86
+
87
+ == Upgrade Notice ==
88
+ = 1.0.2 =
89
+ * Bug Fix: Improved parsing while importing product price with currency symbol and thousand separator.
90
+ = 1.0.1 =
91
+ * Bug Fix: Fixed issue with Evaluation field with single quotes.
92
+ * Bug Fix: Option to import gallery images.
93
+ * Enhancement: Improved help text for Post name and Stock quantity.
94
+ * Enhancement: Improved label text for Product type, category , tags and shipping class.
95
+ * Enhancement: Included links to Documentation and sample CSV.
96
+ = 1.0.0 =
97
* Import /Export Woocommerce Products.