我有Nette和Doctrine 2的項目。 當我想從Doctrine 2的表單中保存CKeditor的值時,它會裁剪相同的HTML標籤,並且不會保存好。 我的方法保存文章。如何通過Doctrine 2保存到DB CKeditor的值
public function addArticle($creator, $data) {
$article = new Article();
$article->setCategory($data->category);
$article->setContent($data->content);
$article->setTitle($data->title);
$this->em->persist($article);
$this->em->flush();
}
變量$數據 - >內容具有價值:
<h1>My first article</h1>
<p><strong>One bold line</strong></p>
.
.
但它保存到數據庫:
<h1>My first article</h1>
<p>
你知道,它的錯誤?如何使用Doctrine 2保存CKeditor的值
對不起。 :((我有db的列爲varchar(45)。我感覺不好。 – ondrusu