woocsv_before_csv_upload

The Woocommerce CSV Import woocsv before csv upload hook.

Description

do_action( 'woocsv_before_csv_upload', (string) $filename ); 

Parameters (1)

0. $filename (string)
The filename.

Usage

To run the hook, copy the example below.
  1. // run the action 
  2. do_action( 'woocsv_before_csv_upload', $filename ); 
The following example is for adding a hook callback.
  1. // define the woocsv_before_csv_upload callback 
  2. function action_woocsv_before_csv_upload( $filename ) { 
  3. // make action magic happen here... 
  4. }; 
  5.  
  6. // add the action 
  7. add_action( 'woocsv_before_csv_upload', 'action_woocsv_before_csv_upload', 10, 1 ); 
To remove a hook callback, use the example below.
  1. // remove the action 
  2. remove_action( 'woocsv_before_csv_upload', 'action_woocsv_before_csv_upload', 10, 1 ); 

Defined (1)

The action is defined in the following location(s).

/include/class-woocsv-import.php  
  1. do_action( 'woocsv_before_csv_upload', $filename );