php programming bug

fclose(): supplied argument is not a valid stream resource

file does not exist Note: file does actually exist
Warning: fclose(): supplied argument is not a valid stream resource in Note: error message displayed when php.ini set to display_errors = On
file could not be closedNote: because supposedly it does not exist.

discovered cause of bug: class constructor was malformed attributed to programmer error.

public function _construct(){ Note: only one underscore character before construct caused problem.
public function __construct(){ Note: placing additional underscore before construct solved problem.


Valid XHTML 1.0 Strict