public function prevLink($post, $title = '', $htmlAttributes = array())
{
$BlogPost = ClassRegistry::init('Blog.BlogPost');
$_htmlAttributes = array('class' => 'prev-link', 'arrow' => '≪ ');
$htmlAttributes = am($_htmlAttributes, $htmlAttributes);
$arrow = $htmlAttributes['arrow'];
unset($htmlAttributes['arrow']);
$conditions = array();
$conditions['BlogPost.posts_date <'] = $post['BlogPost']['posts_date'];
$conditions["BlogPost.blog_content_id"] = $post['BlogPost']['blog_content_id'];
$conditions = am($conditions, $BlogPost->getConditionAllowPublish());
// 毎秒抽出条件が違うのでキャッシュしない
$prevPost = $BlogPost->find('first', array('conditions' => $conditions, 'fields' => array('no', 'name'), 'order' => 'posts_date DESC', 'recursive' => 0, 'cache' => false));
if ($prevPost) {
$no = $prevPost['BlogPost']['no'];
if (!$title) {
$title = $arrow . $prevPost['BlogPost']['name'];
}
$this->BcBaser->link($title, $this->request->params['Content']['url'] . 'archives/' . $no, $htmlAttributes);
}
}