json is now working in the view