Puting html code in Json

I want to add html to Json file in my site but it doesnt come out right, i also used online generators but it didnt help. any suggestion?

1 Like

Can you be more specific about what you are trying to do, and what happens when you do it?

Are you trying to save strings containing HTML in a JSON file, and then insert those into a web page? If so, you might have an escaping problem. A few things to check:

  • Is your JSON file valid? Your text editor should help you with this.
  • Does your code work if you test with plain text rather than HTML inside your JSON file?

If you provide more information we might be able to help you.

1 Like

I was using a tool that a friend of mine developed and that was the reason for the problem.
He is working on a “editor-like” app that helps you code in one platform, but it has lots of bugs i think.
thanks for your answer.
when i was placing html code, the editor was seeing it as plain text.
the problem with online generators was escaping as you mentioned.
peace