php - Fetching remote XML file returns strange string -


i've got weird problem. when go url in browser, nicely formatted xml structure in return.

<root>  <contents/> </root> 

(fake data though)

but when use curl, file_get_contents (or wget in linux) sort of serialized data wich unusable me.``

{"root:{"contents etc.

anyone knows why , how fix it?

it's json.
use json_decode function parse it.


Comments

Popular posts from this blog

c# - SharpSVN - How to get the previous revision? -

c++ - Is it possible to compile a VST on linux? -

url - Querystring manipulation of email Address in PHP -