Source for file Piirkond.php

Documentation is available at Piirkond.php

  1. <?php
  2. /**
  3.  * Model for handling queries with database table 'piirkond'.
  4.  * 
  5.  * @author Margus Sellin <margus@bitweb.ee>
  6.  * @copyright Copyright (C) 2011. All rights reserved. Margus Sellin
  7.  * @package Model
  8.  * @project olymp
  9.  * 
  10.  */
  11.     class Model_Piirkond extends Zend_Db_Table_Abstract {
  12.         /**
  13.          * Database table name
  14.          * @access protected
  15.          * @var string 
  16.          */
  17.         protected $_name = 'piirkond';
  18.  
  19.         /**
  20.          * Query fetchByName.
  21.          * Database query that fetches a row from 'piirkond' table where
  22.          * column 'nimetus' equals the given parameter.
  23.          * 
  24.          * @access public
  25.          * @param string $name Area name
  26.          * @return mixed $result Query resultset
  27.          */
  28.         public function fetchByName($name)
  29.         {
  30.             $select $this->select();
  31.             $select->from($this)
  32.                     ->where('nimetus = ?'$name);
  33.             $result $this->fetchRow($select);
  34.             return $result;
  35.         }
  36.  
  37.     }
  38. ?>

Documentation generated on Mon, 20 Jun 2011 05:43:07 +0300 by phpDocumentor 1.4.1