I installed the JMSSerializerbundle
with symfony2 to get JSON response of my Doctrine Entities.
The problem is that when I have a string field created by ckeditor and content HTML
tags I got an invalid JSON response.
"courses": [
{
"requests": [
],
"id": 38,
"course_content": "
pmlllo<\/p>",
"course_title": "hhjhhhh",
"course_type": {
"id": 3,
"name": "Dershane Dersi",
"courses": [
]
},
"description": "
ppoookokokok<\/p>"
}
]
Using http://jsonlint.com/ I got this error
Parse error on line 154:...
"course_content": "pmlllo</p>",
-----------------------^
Expecting 'STRING', 'NUMBER', 'NULL', 'TRUE', 'FALSE', '{', '['