View Issue Details

IDProjectCategoryView StatusLast Update
0013958mantisbtcsvpublic2014-09-23 18:05
Reporterdregad Assigned Todregad  
PrioritynormalSeverityminorReproducibilityalways
Status closedResolutionfixed 
Product Version1.2.5 
Target Version1.2.9Fixed in Version1.2.9 
Summary0013958: Extra column in csv export when sponsorship_total >= 1000
Description

The fix for 0012772 introduced a bug when the sponsorship_total column is >= 1000 (however unlikely that is to ever happen).

Due to the use of number_format() function with default parameters, PHP outputs the sponsorship amount formatted with ',' as a thousands separator, which also happens to be MantisBT's default csv separator.

Since the fields are not escaped, this causes an extra column to be generated, e.g.


Id,Summary,US$
0000009,test issue,5,000

TagsNo tags attached.

Relationships

related to 0012772 closeddhx Fatal error: Call to undefined function csv_format_sponsorship_total() 
related to 0015721 closedgrangeway Functionality to consider porting to master-2.0.x 

Activities

grangeway

grangeway

2013-04-05 17:57

reporter   ~0036367

Marking as 'acknowledged' not resolved/closed to track that change gets ported to master-2.0.x branch

Related Changesets

MantisBT: master 1d2a0355

2012-02-27 11:12

dregad


Details Diff
Extra column in csv export when sponsorship_total >= 1000

Bug introduced by commit 169b882b97b0c6cf1babbf072ce326f0779c6c0b.

Due to the use of number_format() function with default parameters, PHP
outputs the sponsorship amount formatted with ',' as a thousands
separator, which also happens to be MantisBT's default csv separator.
Since the fields are not escaped, this causes an extra column to be
generated.

Call to number_format() was removed, as it makes more sense to output
raw data in csv exports.

Fixes 0013958
Affected Issues
0013958
mod - core/csv_api.php Diff File

MantisBT: master-1.2.x 0791a497

2012-02-27 11:12

dregad


Details Diff
Extra column in csv export when sponsorship_total >= 1000

Bug introduced by commit a786f9badbccd329e5acec46d2f715219b9e99fc.

Due to the use of number_format() function with default parameters, PHP
outputs the sponsorship amount formatted with ',' as a thousands
separator, which also happens to be MantisBT's default csv separator.
Since the fields are not escaped, this causes an extra column to be
generated.

Call to number_format() was removed, as it makes more sense to output
raw data in csv exports.

Fixes 0013958
Affected Issues
0013958
mod - core/csv_api.php Diff File