I am using PHP curl to get data from an API. I want to print main heading only 1 time, but now it is printing more than one time if there is .. Following is my code.Data is