Skip to content
Advertisement

JavaScript JSON output into a or a

JavaScript

I have this code which works ok, the response from page somepage.php is this:

JavaScript

Which is evaluated as JavaScript and returns it as plain text.

My question is: how do I put the output into a debug <textarea id="something"><textarea> … or a div, to view the output for debugging?

Advertisement

Answer

Use jQuery.text();

JavaScript

Cheers!

User contributions licensed under: CC BY-SA
10 People found this is helpful
Advertisement