Model Behaviors

Behaviors are shared conducts that several models may adopt in order to re-use code, the ORM provides an API to implement behaviors in your models. Also, you can use the events and callbacks as seen before as an alternative to implement Behaviors with more freedom. A behavior must be added in the model initializer, a model can have zero or more behaviors: use Phalcon\Mvc\Model; use Phalcon\Mvc\Model\Behavior\Timestampable; class Users extends Model { public $id; public $name; pub

Cache\Frontend\Output::isBuffering

public isBuffering () Check whether if frontend is buffering output

Mvc\Model\ManagerInterface::getHasOne

abstract public getHasOne (Phalcon\Mvc\ModelInterface $model) ...

Security

implements Phalcon\Di\InjectionAwareInterface Source on GitHub This component provides a set of functions to improve the security in Phalcon applications $login = $this->request->getPost('login'); $password = $this->request->getPost('password'); $user = Users::findFirstByLogin($login); if ($user) { if ($this->security->checkHash($password, $user->password)) { //The password is valid } } Constants integer CRYPT_DEFAULT integer CRYPT_STD_DES integer

Mvc\ModelInterface::assign

abstract public assign (array $data, [mixed $dataColumnMap], [mixed $whiteList]) ...

Cli\Dispatcher::setTaskName

public setTaskName (mixed $taskName) Sets the task name to be dispatched

Cache\Backend\Mongo::gc

public collection->remove(...) gc () gc

Queue\Beanstalk::DEFAULT_HOST

string DEFAULT_HOST

Cli\RouterInterface::getMatchedRoute

abstract public getMatchedRoute () ...

Cache\Frontend\Igbinary::beforeStore

public string beforeStore (mixed $data) Serializes data before storing them