ACC SHELL
<?php
/* $Id */
class Article extends AppModel
{
var $name = 'Article';
var $validate = array(
'perex' => VALID_NOT_EMPTY,
'content' => VALID_NOT_EMPTY,
'title' => VALID_NOT_EMPTY
);
/**
*
*/
function beforeSave()
{
$this->data['Article']['content']
= $this->_cleanHTML($this->data['Article']['content']);
$this->data['Article']['perex']
= $this->_cleanHTML($this->data['Article']['perex']);
return true;
}
/**
*
*/
function afterSave()
{
$this->_clearCache();
}
/**
*
*/
function afterDelete()
{
$this->_clearCache();
}
}
?>
ACC SHELL 2018