skip to Main Content

Display json_encode array from ajax result – Jquery ajax

I have this result {"policy":[{"id":"1","policy_name":"Policy 1","description":"Testing","status":"Active","valid_until":"2022-05-18","tags":"Test","active":"0","date_added":"2022-05-18 05:36:02"}]} And I want to display the policy_name from the array and I've tried to alert it using this alert(response['policy'].policy_name); but I have an error. 43:4801 Uncaught TypeError: Cannot read properties of undefined (reading…

VIEW QUESTION
Back To Top
Search