Ejemplo n.º 1
0
	function startTimer($name){
		$timer = new SI_Timer();
		$timer->name = $name;
		$timer->user_id = $this->id;
		if($timer->add() == FALSE){
			$this->error = 'SI_User::startTimer(): '.$timer->getLastError();
			return FALSE;
		}
		
		if($timer->start() === FALSE){
			$this->error = 'SI_User::startTimer(): '.$timer->getLastError();
			return FALSE;
		}
		
		return $timer;
	}