mirror of
https://github.com/Combodo/iTop.git
synced 2026-04-22 01:58:47 +02:00
Export.php - fixed a regression (specifying no field list resulting in an error)
SVN:trunk[1484]
This commit is contained in:
@@ -48,9 +48,14 @@ $sFormat = strtolower(utils::ReadParam('format', 'html'));
|
||||
|
||||
$sFields = utils::ReadParam('fields', '', true, 'raw_data'); // CSV field list (allows to specify link set attributes, still not taken into account for XML export)
|
||||
$aFields = explode(',', $sFields);
|
||||
foreach($aFields as &$sField)
|
||||
// Clean the list of columns (empty it if every string is empty)
|
||||
foreach($aFields as $index => $sField)
|
||||
{
|
||||
$sField = trim($sField);
|
||||
$aFields[$index] = trim($sField);
|
||||
if(strlen($aFields[$index]) == 0)
|
||||
{
|
||||
unset($aFields[$index]);
|
||||
}
|
||||
}
|
||||
|
||||
$oP = null;
|
||||
|
||||
Reference in New Issue
Block a user