hello.
I'm trying to use uTorrent webUI API. I think this is a pretty n00b question but there's little documentation about this API on the web, sorry.
my server uses file_get_contents($url) and I get the data I want. but in a format I do not understand.
for example:
{
"build": BUILD NUMBER (integer),
"label": [
[
LABEL (string),
TORRENTS IN LABEL (integer)
],
...
],
"torrents": [
[
HASH (string),
STATUS* (integer),
NAME (string),
SIZE (integer in bytes),
PERCENT PROGRESS (integer in per mils),
DOWNLOADED (integer in bytes),
UPLOADED (integer in bytes),
RATIO (integer in per mils),
UPLOAD SPEED (integer in bytes per second),
DOWNLOAD SPEED (integer in bytes per second),
ETA (integer in seconds),
LABEL (string),
PEERS CONNECTED (integer),
PEERS IN SWARM (integer),
SEEDS CONNECTED (integer),
SEEDS IN SWARM (integer),
AVAILABILITY (integer in 1/65536ths),
TORRENT QUEUE ORDER (integer),
REMAINING (integer in bytes)
],
...
],
"torrentc": CACHE ID** (string integer)
}
torrent are like [a,b,c,d]. and each torrents are separeted by commas
so I end up with a file like this: [a,b,c,d],[a,b,c,d],[a,b,c,d]. I don't know if this structure has a name.
now, how can I transform that into something more readable like XML? thanks