PEAR is archived and read-only

This mirror preserves historical PEAR package releases and metadata so existing references remain available.

Home » File Formats » Spreadsheet_Excel_Writer » Bug #7840

Notices on default formats

Details

Submitted2006-06-08 20:35 UTC
Fromkostya dot belov at gmail dot com
Assignedtuupola
StatusClosed
PackageSpreadsheet_Excel_Writer
PHP Version5.1.4
OSLinux
Roadmaps(Not assigned)

Comments

[2006-06-08 20:35 UTC] kostya dot belov at gmail dot com

Description:
------------
On max error_reporting level I have got notices at /usr/local/lib/php/Spreadsheet/Excel/Writer/Worksheet.php. Line numbers: 1233 and 1686.

What's happenning: at line 3502 default value for $format parameter is ZERO. At line 1233 $format is compared to ZERO and that is ok, unless you pass OBJECT as format parameter to writeNumber function. In that case PHP 5.1.4 produces notice "attempt to convert OBJECT to INT".

Solution: use "null" as default value for $format argument of writeNumber and compare it to "null" but not ZERO (integer).

[2006-06-22 12:30 UTC] pear dot php dot net at chsc dot dk

This is a duplicate of bug 6509.

[2006-09-21 12:19 UTC] tuupola at php dot net

This bug has been fixed in CVS.

If this was a documentation problem, the fix will appear on pear.php.net by the end of next Sunday (CET).

If this was a problem with the pear.php.net website, the change should be live shortly.

Otherwise, the fix will appear in the package's next release.

Thank you for the report and for helping us make PEAR better.