<?php
use Phalcon\Forms\Form; use Phalcon\Forms\Element\Text; use Phalcon\Forms\Element\Hidden;
class ContactForm extends Form { public function getCsrf() { return $this->security->getToken(); }
public function initialize()
{
$this->setEntity($this);
// Add a text element to capture the 'email'
$this->add(new Text("email"));
// Add a text element to put a hidden CSRF
$this->add(new Hidden("csrf"));
}
} what $this->setEntity($this) ?. Please help me.I do not understand, please give me an example