function __construct($id = 0) { parent::__construct(); $this->properties['posts'] = array('id', 'hash_code', 'content_type', 'hash_code_author', 'date_created', 'date_editing', 'title', 'title_for_url', 'text_post', 'tags', 'attached_file', 'views'); if ($id) { $this->getData($id); } }