WC_CSV_Exporter::set_filename()publicWC 1.0

Set filename to export to.

Method of the class: WC_CSV_Exporter{}

No Hooks.

Return

null. Nothing (null).

Usage

$WC_CSV_Exporter = new WC_CSV_Exporter();
$WC_CSV_Exporter->set_filename( $filename );
$filename(string) (required)
Filename to export to.

WC_CSV_Exporter::set_filename() code WC 9.4.2

public function set_filename( $filename ) {
	$this->filename = sanitize_file_name( str_replace( '.csv', '', $filename ) . '.csv' );
}