Filter
rpress_customers_export_filename
On this page
Filters the file name of the customers CSV export.
Runs when the customers CSV export sends its download headers. The value has no extension; .csv is appended afterwards. When the export is limited to a single menu item, the title of that item is part of the default name.
Parameters#
| Parameter | Type | Description |
|---|---|---|
$filename | string | Default name: rpress-export-, the menu item title if any, the export type, then the date as m-d-Y. |
Return value#
string. The file name without the .csv extension.
Example#
function my_customers_export_filename( $filename ) {
return 'mysite-' . $filename;
}
add_filter( 'rpress_customers_export_filename', 'my_customers_export_filename', 10, 1 );
Source#
Applied in:
includes/admin/reporting/class-export-customers.php(line 44), inRPRESS_Customers_Export::headers()
See also#
Was this page helpful?
