Blame | Letzte Änderung | Log anzeigen | RSS feed
<?php/*** @author Lars Tiefland* @copyright 2012*/namespace Weban;class hersteller{public function __construct( $id ){$sql = "SELECTid,name,logo,homepageFROMherstellerWHEREid = $id";$res = $GLOBALS["db"]->query( $sql );$row = $res->fetchRow();$this->id = $row["id"];$this->name = $row["name"];$this->logo = $row["logo"];$this->homepage = $row["homepage"];}public static function Liste(){$sql = "SELECTidFROMhersteller";$res = $GLOBALS["db"]->query( $sql );while ( $row = $res->fetchRow() ){$ret[] = new hersteller( $row["id"] );}return $ret;}}?>