Add links to importers on post list screens
This commit is contained in:
@@ -20,7 +20,7 @@ if ( class_exists( 'WP_Importer' ) ) {
|
||||
* @return void
|
||||
*/
|
||||
public function __construct() {
|
||||
$this->import_page = 'sportspress_staff_csv';
|
||||
$this->import_page = 'sp_staff_csv';
|
||||
$this->import_label = __( 'Import Staff', 'sportspress' );
|
||||
$this->columns = array(
|
||||
'post_title' => __( 'Name', 'sportspress' ),
|
||||
@@ -165,7 +165,7 @@ if ( class_exists( 'WP_Importer' ) ) {
|
||||
echo '<div class="narrow">';
|
||||
echo '<p>' . __( 'Hi there! Choose a .csv file to upload, then click "Upload file and import".', 'sportspress' ).'</p>';
|
||||
echo '<p>' . sprintf( __( 'Staff need to be defined with columns in a specific order (6 columns). <a href="%s">Click here to download a sample</a>.', 'sportspress' ), plugin_dir_url( SP_PLUGIN_FILE ) . 'dummy-data/staff-sample.csv' ) . '</p>';
|
||||
wp_import_upload_form( 'admin.php?import=sportspress_staff_csv&step=1' );
|
||||
wp_import_upload_form( 'admin.php?import=sp_staff_csv&step=1' );
|
||||
echo '</div>';
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user