Heads up!
This article contains PHP code and is intended for developers. We offer this code as a courtesy, but don't provide support for code customizations or 3rd party development.
This article contains PHP code and is intended for developers. We offer this code as a courtesy, but don't provide support for code customizations or 3rd party development.
This filter allows you to manipulate the line breaks in the .csv file.
Usage
add_filter('frm_export_csv_line_break', 'custom_function');
Parameters
- $line_break (string): The line break in CSV data. By default, it is return, which is rn, r or n.
Examples
Change line break of CSV
Use this code example to change the line break of CSV to '|'. It will prevent paragraphs fields (and other fields that may have line breaks in them) from being fragmented when being imported as an .csv file.
add_filter( 'frm_export_csv_line_break', 'change_csv_line_break');
function change_csv_line_break( $line_break ) {
return '|';
}