[dev] Re: [cvs] commit: imp/lib/MIME/Viewer tnef.php
   
    Michael M Slusarz
     
    slusarz@bigworm.colorado.edu
       
    Mon,  3 Jun 2002 21:50:10 -0600
    
    
  
Quoting Chuck Hagenbuch <chuck@horde.org>:
| 
| As long as you check boundary conditions that might cause errors (not
| sure 
| how passing in a before the beginning/after the end position might effect
| things here), that should be fine, yeah...
| 
Yup - we just use array_key_exists() and if the index doesn't exist, we 
print an error.
BTW, just a style thing, but I have noticed that (generally) isset() is 
used in the codebase to check for the existence of an array key.  I read in 
an article somewhere, and have been trying to do this myself, that 
array_key_exists() is the preferable means of doing this.  (It is true that 
array_key_exists() has only been around since PHP 4.1.0).  If I remember 
correctly, the two reasons to use it instead are 1) it is more a more clear 
description and 2) isset does not work if the value is NULL.  Just wanted 
to throw this out there.
And I think I will just go ahead and throw the tnef MIME Viewer into Horde 
instead.
michael
______________________________________________
Michael Slusarz [slusarz@bigworm.colorado.edu]
The University of Colorado at Boulder