numFields(); // loop over all of the fields for($i=0; $i<$fieldcount; $i++) { // decode each field name ready for encoding when it goes through serialization // and save each field name into the array $this->columns[] = $d->fieldName($i); } if($d->numRows() > 0) { $this->rows = $d->fetchAll(SQLITE_NUM); } } } ?>