I am writing a script using jQuery for loading some content into my page. At runtime nothing happens. I get this error when inspecting Firebug console:
TypeError: cyclic object value
data: JSON.stringify({ columnName: _columnName })
Here is the code (placed inside <Head>):
<Script>
function changeContent(_columnName) {
$.ajax({
type: 'POST',
url: '@Url.Action("GetContent")',
data: JSON.stringify({ columnName: _columnName }),
dataType: 'json',
contentType: "application/json; charset=utf-8"
}).done(function (resp) {
CKEDITOR.instances.text.setData(resp.Text);
}).fail(function () {
alert("Error");
});
}
$(function () {
$("#side-content").bind('click', { a: "side" }, changeContent);
});
</Script>
I used the tip here: Detecting and fixing circular references in JavaScript but could not find any circular relations!!!
Any point on saving my life would be so greatly appreciated.
- Kamran