This topic is locked

Problem with & in CSV export

5/28/2008 4:25:01 PM
PHPRunner General questions
D
dphipson author

Hi,
I have a data field (company name) that contains an &. It works perfectly well - i.e. the & displays correctly in enquiries, maintenance screens and reports. When I export the data to an Excel file it works fine, however when I export it to a CSV file (using the export function within PHPRunner) the & gets converted to &. Any ideas why? What can I do to resolve this issue?
Thanks in advance.
Regards,
Darren

M
mickmouser 5/28/2008

Hello:
I have the same problem with all my tradmark and copyright circles. They revert to whatever.
Thanks, Janice

J
Jane 5/29/2008

Hi,
to replace & with & in teh export file edit generated ..._export.php file.

Locate ExportToCSV() function, find this code:

$outstr.='"'.htmlspecialchars(GetData($row,"FieldName",$format)).'"';



and replace it with this one:

$outstr.='"'.GetData($row,"FieldName",$format).'"';