Simple XML PHP error - Echo's nothing

uh-huh

New Member
Ok guys,Essentially, im loading a simplexml_load_file from a URL like this\[code\]$stats = simplexml_load_file("http://example.com/api/api.asmx/Campaign.GetSummary?ApiKey=$apikey&CampaignID=$CID");\[/code\]Which returns this\[code\]SimpleXMLElement Object( [Recipients] => 1 [TotalOpened] => 0 [Clicks] => 0 [Unsubscribed] => 0 [Bounced] => 0 [UniqueOpened] => 0)\[/code\]After I load that up I want to echo the info, so I try to echo it out like so\[code\]echo '<ul id="views">'; echo '<li>';print $stats['Recipients'];echo '</li>';echo '</ul>';\[/code\]But when it runs, I dont get any of the data, just an empty \[code\]<li></li>\[/code\]Any help would be greatly appreciated guys, Thanks in advance.
 
Back
Top