static function getByText($section, $type) { static $cache = array(); $tmp =& $cache[$section][$type]; if (!isset($tmp)) { $statType = new self(); $statType->section = $section; $statType->type = $type; $statType->findOrSave(); $tmp = $statType->id; } return $tmp; }