Version Description
Download this release
Release Info
Developer | soflyy |
Plugin | Import Products from any XML or CSV to WooCommerce |
Version | 1.1.1 |
Comparing to | |
See all releases |
Code changes from version 1.1.0 to 1.1.1
- helpers/pmwi_sanitize_taxonomy_name.php +12 -0
- models/import/record.php +1 -1
- plugin.php +7 -2
- readme.txt +2 -0
- static/css/admin.css +1 -1
helpers/pmwi_sanitize_taxonomy_name.php
ADDED
@@ -0,0 +1,12 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
|
3 |
+
function pmwi_sanitize_taxonomy_name($taxonomy){
|
4 |
+
$filtered = strtolower( remove_accents( stripslashes( strip_tags( $taxonomy ) ) ) );
|
5 |
+
$filtered = preg_replace( '/&.+?;/', '', $filtered ); // Kill entities
|
6 |
+
$filtered = str_replace( array( '.', '\'', '"' ), '', $filtered ); // Kill quotes and full stops.
|
7 |
+
$filtered = str_replace( array( ' ', '_' ), '-', $filtered ); // Replace spaces and underscores.
|
8 |
+
|
9 |
+
return apply_filters( 'sanitize_taxonomy_name', $filtered, $taxonomy );
|
10 |
+
}
|
11 |
+
|
12 |
+
?>
|
models/import/record.php
CHANGED
@@ -556,7 +556,7 @@ class PMWI_Import_Record extends PMWI_Model_Record {
|
|
556 |
if ( ! taxonomy_exists( $woocommerce->attribute_taxonomy_name( $attr_name ) ) and intval($attr_data['is_create_taxonomy_terms'][$i])) {
|
557 |
|
558 |
// Grab the submitted data
|
559 |
-
$attribute_name = ( isset( $attr_name ) ) ?
|
560 |
$attribute_label = ucwords( stripslashes( (string) $attr_name ));
|
561 |
$attribute_type = 'select';
|
562 |
$attribute_orderby = 'menu_order';
|
556 |
if ( ! taxonomy_exists( $woocommerce->attribute_taxonomy_name( $attr_name ) ) and intval($attr_data['is_create_taxonomy_terms'][$i])) {
|
557 |
|
558 |
// Grab the submitted data
|
559 |
+
$attribute_name = ( isset( $attr_name ) ) ? pmwi_sanitize_taxonomy_name( stripslashes( (string) $attr_name ) ) : '';
|
560 |
$attribute_label = ucwords( stripslashes( (string) $attr_name ));
|
561 |
$attribute_type = 'select';
|
562 |
$attribute_orderby = 'menu_order';
|
plugin.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
Plugin Name: WP All Import - WooCommerce Add-On
|
4 |
Plugin URI: http://www.wpallimport.com/
|
5 |
Description: An extremely easy, drag & drop importer to import WooCommerce simple products. A paid upgrade is available for premium support and support for Variable, Grouped, and External/Affiliate products
|
6 |
-
Version: 1.1.
|
7 |
Author: Soflyy
|
8 |
*/
|
9 |
/**
|
@@ -24,7 +24,7 @@ define('PMWI_FREE_ROOT_URL', rtrim(plugin_dir_url(__FILE__), '/'));
|
|
24 |
*/
|
25 |
define('PMWI_PREFIX', 'pmwi_');
|
26 |
|
27 |
-
define('PMWI_FREE_VERSION', '1.1.
|
28 |
|
29 |
define('PMWI_EDITION', 'free');
|
30 |
|
@@ -161,6 +161,11 @@ final class PMWI_Plugin {
|
|
161 |
}
|
162 |
spl_autoload_register(array($this, '__autoload'));
|
163 |
|
|
|
|
|
|
|
|
|
|
|
164 |
// init plugin options
|
165 |
$option_name = get_class($this) . '_Options';
|
166 |
$options_default = PMWI_Config::createFromFile(self::ROOT_DIR . '/config/options.php')->toArray();
|
3 |
Plugin Name: WP All Import - WooCommerce Add-On
|
4 |
Plugin URI: http://www.wpallimport.com/
|
5 |
Description: An extremely easy, drag & drop importer to import WooCommerce simple products. A paid upgrade is available for premium support and support for Variable, Grouped, and External/Affiliate products
|
6 |
+
Version: 1.1.1
|
7 |
Author: Soflyy
|
8 |
*/
|
9 |
/**
|
24 |
*/
|
25 |
define('PMWI_PREFIX', 'pmwi_');
|
26 |
|
27 |
+
define('PMWI_FREE_VERSION', '1.1.1');
|
28 |
|
29 |
define('PMWI_EDITION', 'free');
|
30 |
|
161 |
}
|
162 |
spl_autoload_register(array($this, '__autoload'));
|
163 |
|
164 |
+
// register helpers
|
165 |
+
if (is_dir(self::ROOT_DIR . '/helpers')) foreach (PMWI_Helper::safe_glob(self::ROOT_DIR . '/helpers/*.php', PMWI_Helper::GLOB_RECURSE | PMWI_Helper::GLOB_PATH) as $filePath) {
|
166 |
+
require_once $filePath;
|
167 |
+
}
|
168 |
+
|
169 |
// init plugin options
|
170 |
$option_name = get_class($this) . '_Options';
|
171 |
$options_default = PMWI_Config::createFromFile(self::ROOT_DIR . '/config/options.php')->toArray();
|
readme.txt
CHANGED
@@ -54,6 +54,8 @@ You need the WooCommerce add-on if you need to:
|
|
54 |
* Import CSV to WooCommerce
|
55 |
* Are frustrated with the limitations of the official WooThemes Product CSV Import Suite
|
56 |
|
|
|
|
|
57 |
== Installation ==
|
58 |
|
59 |
First, install [WP All Import](http://wordpress.org/plugins/wp-all-import "WordPress XML & CSV Import").
|
54 |
* Import CSV to WooCommerce
|
55 |
* Are frustrated with the limitations of the official WooThemes Product CSV Import Suite
|
56 |
|
57 |
+
Follow [@WPAllImport](http://www.twitter.com/WPAllImport) on Twitter.
|
58 |
+
|
59 |
== Installation ==
|
60 |
|
61 |
First, install [WP All Import](http://wordpress.org/plugins/wp-all-import "WordPress XML & CSV Import").
|
static/css/admin.css
CHANGED
@@ -70,7 +70,7 @@
|
|
70 |
width:152px !important;
|
71 |
}
|
72 |
.pmxi_plugin ul.wc-tabs li.active a{
|
73 |
-
width:120px !important
|
74 |
background-color: #fff !important;
|
75 |
}
|
76 |
.pmxi_plugin .fleft{
|
70 |
width:152px !important;
|
71 |
}
|
72 |
.pmxi_plugin ul.wc-tabs li.active a{
|
73 |
+
/*width:120px !important;*/
|
74 |
background-color: #fff !important;
|
75 |
}
|
76 |
.pmxi_plugin .fleft{
|