Here's 2 javascript variables:
<script language="javascript" type="text/javascript">
var example1 = 'Mr.:1|Mrs.:2|Ms.:3|Dr.:4|Sr.:5|Jr.:6';
var example2 = {'Mr.':'1','Mrs.':'2','Ms.':'3','Dr.':'4','Sr.':'5','Jr.':'6'}
</script>
With javascript, is there a way to detect which one is not json?
"), therefore neither example above is JSON. For the full spec, see this page.