no need to add quote marks for excel output
This commit is contained in:
@@ -592,9 +592,9 @@ function booking_varietysessions_csv_report($timeslot_id) {
|
|||||||
//make the column headings a bit more user friendly
|
//make the column headings a bit more user friendly
|
||||||
$heading = $variety_sessions[$column]->booking_variety_descrip;
|
$heading = $variety_sessions[$column]->booking_variety_descrip;
|
||||||
//enclose $heading if necessary
|
//enclose $heading if necessary
|
||||||
if ( $encloseAll || preg_match( "/(?:${delimiter_esc}|${enclosure_esc}|\s)/", $heading ) ) {
|
//if ( $encloseAll || preg_match( "/(?:${delimiter_esc}|${enclosure_esc}|\s)/", $heading ) ) {
|
||||||
$heading = $enclosure . str_replace($enclosure, $enclosure . $enclosure, $heading) . $enclosure;
|
// $heading = $enclosure . str_replace($enclosure, $enclosure . $enclosure, $heading) . $enclosure;
|
||||||
}
|
//}
|
||||||
|
|
||||||
// Adjusted for excel, assume each column is just a string
|
// Adjusted for excel, assume each column is just a string
|
||||||
//$column_headings[] = array($heading => 'string');
|
//$column_headings[] = array($heading => 'string');
|
||||||
@@ -612,12 +612,12 @@ function booking_varietysessions_csv_report($timeslot_id) {
|
|||||||
$field = isset($data[$column][$i]) ? $data[$column][$i] : '';
|
$field = isset($data[$column][$i]) ? $data[$column][$i] : '';
|
||||||
|
|
||||||
//enclose $field if necessary
|
//enclose $field if necessary
|
||||||
if ( $encloseAll || preg_match( "/(?:${delimiter_esc}|${enclosure_esc}|\s)/", $field ) ) {
|
//if ( $encloseAll || preg_match( "/(?:${delimiter_esc}|${enclosure_esc}|\s)/", $field ) ) {
|
||||||
$output[] = $enclosure . str_replace($enclosure, $enclosure . $enclosure, $field) . $enclosure;
|
// $output[] = $enclosure . str_replace($enclosure, $enclosure . $enclosure, $field) . $enclosure;
|
||||||
}
|
//}
|
||||||
else {
|
//else {
|
||||||
$output[] = $field;
|
$output[] = $field;
|
||||||
}
|
//}
|
||||||
} //loop through columns
|
} //loop through columns
|
||||||
$rows[] = $output;
|
$rows[] = $output;
|
||||||
//$row = implode($delimiter, $output) . "\n";
|
//$row = implode($delimiter, $output) . "\n";
|
||||||
|
Reference in New Issue
Block a user