Php calling XML Attribute

Hey folks,

Basically I’m using a bit of php which converts the xml values into html.

This feed

http://ws.audioscrobbler.com/1.0/artist/Metallica/fans.xml

I’m using simple statments such as echo $element->weight;
**
and
**
echo $element->url;

these work fine.

I’m trying to call the part ‘user username’ but because its an attribute and has a space, and none of these work.

**echo $element->user;

****echo $element->user username;

**echo $element->username;

Does anyone know what I need to do in this case ?

Any help is much appreciated, it’s been bugging me for a while now !

Thanks,

Aaron