public function postSave($post) { $post_id = $post['id']; if (isset($post['plugin']) && isset($post['plugin'][$this->id])) { if ($post['plugin'][$this->id]) { $tags = preg_split('/(,[\\s]*)+/', $post['plugin'][$this->id]); } else { $tags = array(); } $tag_model = new blogTagPluginModel(); $tag_model->addTag($post_id, $tags); } }