I need to get the elements from xml string.
$DATA = '<totales><DTD><fecha>17/11/2014 11:41:41</fecha><valor>-0.05</valor><profitloss>-0.05</profitloss></DTD><MTD><fecha>noviembre</fecha><valor>2.41</valor></MTD><YTD><fecha>2014</fecha><valor>43.25</valor></YTD><ITD><fecha>2009</fecha><valor>47.09</valor></ITD><IDrawTD><fecha>%Draw</fecha><valor>-1.14</valor></IDrawTD><sumaDay><fecha>17/11/2014 11:41:41</fecha><valor>-0.05</valor></sumaDay> </totales>';
I want to get: 17/11/2014 11:41:41, -0.05,-0.05,noviembre...
I got this $DATA from nusoap $client->responseData, I tried to simplexml_load_string($DATA) and work from there but it seems it doens't get nothing. I also tried to explode,implode,split.. but it doesn't get what is between .
No comments:
Post a Comment