public function getAllModSecConfigurations($where = '') { $str = "SELECT C.ConfID,C.ConfName,C.Description,C.Validity\n FROM modsec_conf C {$where}"; $result = $this->dbh->query($str); if (PEAR::isError($result)) { echo $result->getMessage() . ' - ' . $result->getUserinfo(); exit; } $array = $result->fetchAll(); $result->free(); $msec_conf_a = array(); foreach ($array as $el) { $msec_conf = new ModSecConfiguration(); $msec_conf->setID($el[0]); $msec_conf->setName($el[1]); $msec_conf->setDescription($el[2]); $msec_conf->setActive($el[3]); $msec_conf->setFilled(true); $msec_conf_a[] = $msec_conf; } return $msec_conf_a; }