I have two json data:
$old_data = '{"stock_id":"583",
"stock_date":"2017-03-11",
"stock_quantity_in":"0",
"stock_note":"moved to warehouse A}';
$new_data = '{"stock_id":"583",
"stock_date":"2017-03-11",
"stock_quantity_in":"3",
"stock_note":"moved to warehouse B}';
how do I compare them and highlight the differences? Using php or js are welcome
[UPDATE] I think this one is the closest one I need, thanks!