- Issue created by @steven jones
See https://csv.thephpleague.com/9.0/interoperability/escape-formula-injection/ for documentation of this feature.
Would it be possible for an option to be available whereby the formula injection formatted could be added to the export pipeline please?
Once this is available in this module I'd like to provide support for it in the Views Data Export → module too.
Add support for adding this formatter as per the docs:
use League\Csv\EscapeFormula;
use League\Csv\Writer;
$formatter = new EscapeFormula();
$writer = Writer::createFromPath('php://temp', 'r+');
$writer->addFormatter($formatter->escapeRecord(...));
$writer->insertOne(['2', '2017-07-25', 'Important Client', '=2+5', 240, null]);
$writer->toString();
//outputting a CSV Document with all CSV Formula Injection escaped
//"2,2017-07-25,\"Important Client\",\"\t=2+5\",240,\n"
Write the additional code that'll allow adding this as an option.
None.
Provide a way for consuming modules to add this filter.
None.
Active
4.0
Code