forked from solepixel/bmoney-ultimate-csv-importer
-
Notifications
You must be signed in to change notification settings - Fork 0
/
ultimate-csv-importer.php
64 lines (50 loc) · 1.99 KB
/
ultimate-csv-importer.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
<?php
/*
Plugin Name: BMoney Ultimate CSV Importer
Plugin URI: http://www.infomedia.com/
Description: Imports (almost) anything into WordPress.
Version: 2.3
Author: Brian DiChiara
Author URI: http://www.briandichiara.com
PLUGIN HOOKS:
Actions:
bmuci_before_init - occurs at start of init
var: (object) $this
bmuci_after_init - occurs at end of init
var: (object) $this
bmuci_before_import - occurs at start of import
var: (object) $this
bmuci_after_import - occurs at end of import
var: (object) $this
Filters:
bmuci_customization_methods - custom column customization methods
filter var: (array) $customization_methods
bmuci_sample_data - changes number of sample rows $num_sample_rows displayed
filter var: (int) $num_sample_rows
default: 3
bmuci_post_data - filters post $import_data before inserted into database
filter var: (array) $import_data
other var: (array) $row
bmuci_postmeta_value - filters post meta value $v before inserted/updated into database
filter var: (string) $v
other vars: (int) $post_id, (string) $k, (array) $row
bmuci_user_import_data - filters user import data prior to validation
filter var: (array) $import_data
other var: (array) $row
bmuci_insert_user - filters initial $new_user data before inserting into database (user_login, user_pass, user_email, role)
filter var: (array) $new_user
other vars: (array) $row
bmuci_user_data - filters other user $import_data before inserting into database
filter var: (array) $import_data
other vars: (array) $row
bmuci_usermeta_value - filters user meta $v before inserting/updating into database
filter var: (string) $v
other vars: (int) $user_id, (string) $k, (array) $row
*/
define('BMUCI_VERSION', '2.3');
define('BMUCI_OPT_PREFIX', 'bmuci_');
define('BMUCI_PATH', plugin_dir_path( __FILE__ ));
define('BMUCI_DIR', plugin_dir_url( __FILE__ ));
require_once(BMUCI_PATH.'classes/bm-ultimate-csv-importer.class.php');
$bmuci_plugin = new BM_Ultimate_CSV_Importer();
$bmuci_plugin->initialize();