I\'ve got a php script which generates HTML content. Is there a way to send back that HTML content through JSON to my webpage from the php script?
Do Like this
1st put all your HTML content to array, then do json_encode
json_encode
$html_content="<p>hello this is sample text"; $json_array=array( 'content'=>50, 'html_content'=>$html_content ); echo json_encode($json_array);