Parse Json string with Html content Parse Json string with Html content json json

Parse Json string with Html content


The JSON is invalid, so it can't be parsed. You have to escape the quotation marks inside the string:

string hj = @"{""data"": ""<a href=\""www.google.com\"">Google</a>""}";


Try to encode HTML code with System.Web.HttpUtility.HtmlEncode() method