33 protected $fileResource;
47 $this->inputFile = $file;
48 if(!file_exists($file)) {
53 if(FALSE === ($FD = @fopen($this->inputFile,
'r'))) {
54 throw new Exception(
"Cannot open File $this->inputFile\n");
58 $this->error = $e->getMessage();
61 $this->fileResource = $FD;
65 public function getError(){
69 public function getFileResource(){
70 return($this->fileResource);
91 while($rline = fgets($FD, 1024)) {
94 if ($line ===
"")
continue;
95 if (preg_match(
'/^#/', $line))
continue;
char * trim(char *ptext)
Trimming whitespace.