How To Validate Json Data Using Javascript For Navigation