See https://www.drupal.org/project/csv_serialization/issues/2859030. The patch added by this issue enables the inclusion of a BOM at the start of CSV output when the following conditions are met:

$this->useUtf8Bom = ($settings['encoding'] === 'utf8' && !empty($settings['utf8_bom']));

Note the reference to the setting utf8_bom. I cannot find any reference to this setting elsewhere in the csv_serialisation code so it never passes and the BOM is never included.

Comments

johnvb created an issue. See original summary.

benroy’s picture

I confirm the same issue : I've got a view to export data to csv file, but I can't find the way to add the BOM option...

benroy’s picture

It seems to be used in a patch views_data_export : https://www.drupal.org/project/views_data_export/issues/2859342

Otherwise, you can modify the patch by setting default value to "TRUE"
#66 protected $useUtf8Bom = TRUE;

Not the best way but it works ...

markdorison’s picture

Status: Active » Closed (outdated)

Please reopen with a merge request against 4.x if this issue is still relevant.