I\'m using JQuery to call a PHP function that returns a JSON string upon success or throws some exceptions. Currently I\'m calling jQuery.parseJSON() on the res
jQuery.parseJSON()
echo json_encode(array( 'error' => $e->getMessage(), ));