#10 patch for '0' is not null (empty cell)

v3.0b
open
nobody
None
5
2005-07-25
2005-07-25
xdelacour
No

Here the patch for the rendering of the 0 (integer or
string), in a table.
It's the result of the empty(string) php function that
return false, if argument is 0. (the integer or the string)

the problem appear on line 1754 :

if (empty($vetor[0]) and empty($vetor[7])) continue;

replaced by :

if (empty($vetor[0]) and empty($vetor[7]) and
($vetor[0] != '0') and ($vetor[0] != 0)) continue;

see the attached file

Discussion

  • xdelacour

    xdelacour - 2005-07-25

    0 (empty cell) patched file

     
  • julien mourot

    julien mourot - 2005-10-10

    Logged In: YES
    user_id=1093065

    Hi
    Thanks for your bug report
    There was a side effect with $vetor[0]!=0 , it seems
    "if (empty($vetor[0]) && empty($vetor[7]) && $vetor[0] !=
    '0' ) continue;"
    is enought for rendering 0.
    The patch will be incorporated in the next release of the
    script.

    Regards

     
  • DjDarkman

    DjDarkman - 2007-09-07

    Logged In: YES
    user_id=1437086
    Originator: NO

    Thank you for the patch this bug bothered me two.

     

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks