Asp.net and Jquery return data bug
<p>I have Jquery code behaves weirdly. I am doing a complex task but I am almost done with it. Only problem I have is I am trigering a webmethod in C# which works perfectly. That webmethod returns a string value. I am trying to set a cookie with that returned value but it displays [object Object]. How can I display the returned value properly.</p>

<pre><code>$.ajax({
type: "POST",
url: "InsertPost.aspx/insert_post_new_category",
data: "{'CategoryName':'" + user_cat + "','CategoryDescription':''}",
contentType: "application/json; charset=utf-8",
dataType: "json",
success: function (data, status) {
    if (user_cat.replace(/^\s+|\s+$/g, '') != '') {
        $("#demo-input-facebook-theme").tokenInput("add", { name: user_cat, id: data });
        $.session.set(encodeURIComponent('Kat_' + user_cat + '_x'), data);
    }
}
</code></pre>

<p>});</p>

<p>I am having problem with "data" above. that displays [object Object]. How can I fix this</p>
