Project

General

Profile

Actions

Bug #16966

closed

CSV export stop exporting a field when there is a linebreak

Added by Oliver Klee almost 18 years ago. Updated over 14 years ago.

Status:
Closed
Priority:
Should have
Assignee:
Category:
-
Target version:
-
Start date:
2007-02-10
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
4.1
PHP Version:
4
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

Steps to reproduce:
1. Edit a fe_user record.
2. In the "address field", enter:
a
(linebreak)
b
3. Save.
4. From the list view, do a CSV export.

Expected result:
The corresponding field is exported as "a0x0ab".

Actual result:
The corresponding field is cut of at the linebreak: "a".

(issue imported from #M4957)


Files

0004957.patch (659 Bytes) 0004957.patch Administrator Admin, 2007-02-10 13:20
0004957_v2.patch (642 Bytes) 0004957_v2.patch Administrator Admin, 2007-02-15 16:18
Actions #1

Updated by Oliver Hader almost 18 years ago

CSV allows line-breaks (see http://www.creativyst.com/Doc/Articles/CSV/CSV01.htm#EmbedBRs)
The attached patch file 0004957.patch removes the crop after the first embedded line-break inside a field. Import/export was also tested with OpenOffice and Excel.

Actions #2

Updated by Oliver Klee almost 18 years ago

The patch solves the problem for me.

I've modified the patch to make it even shorter (and a bit more readable). I'll upload it in a minute.

Actions #3

Updated by Thomas Hempel over 17 years ago

Hi,
patch look sgood so far. Wouldn't it a good idea to add a check if $row is really an array? I'm not sure if this is checked somewhere before or if $row is an array in any case. Anyway if it is not, PHP will throw an ugly error.

Greets,
Thomas

Actions #4

Updated by Oliver Klee over 17 years ago

Let's not mix two separate issues into one bug report (or one patch): If there are problems because $row is not checked to be an array, I propose opening a new bug for this - that would be a different issue than the cut-off text in CSV export.

Actions #5

Updated by Ernesto Baschny over 17 years ago

Fixed in trunk for 4.2

Actions

Also available in: Atom PDF