Mailinglisten-Archive |
hallo listenbewohner,
zur Zeit studiere ich die phpdoc-tags und hänge nun schon seit längeren bei den
packages. Ich versuch mehrere Klassen die mehrere Funktion haben, zu einem package
zusammen zufassen.
zb:
<?php
/**
* Pretend this is a file
*
* Page-level DocBlock is here because it is the first DocBlock
* in the file, and is immediately followed by the second
* DocBlock before any documentable element is declared
* (function, define, class, global variable, include)
* @package pagepackage
*/
/**
* Here is the class DocBlock
*
* The class package is different from the page package!
* @package classpackage
*/
class ClassSql {
var $db;
var $res;
function ClassSql( $host, $user, $pass ) {
$this->db = mysql_connect( $host, $user, $pass );
}
function setDB( $database ) {
mysql_select_db( $database, $this->db );
}
function query( $query ) {
$result = mysql_query( $query, $this->db );
$this->res = $result;
return $result;
}
function fetch_array( $result ) {
return mysql_fetch_array( $result );
}
}
?>
kann mir vielleicht jemand sagen wie das wirklich auszusehen hat?
Liebe Grüsse
C.Heimerl
php::bar PHP Wiki - Listenarchive