The XML I am reading looks like this:
The Big Bang Theory
http://www.tvrage.com/The_Bi
You need to use attributes() to get the attributes.
$id = $xml->show->attributes()->id;
You can also do this:
$attr = $xml->show->attributes();
$id = $attr['id'];
Or you can try this:
$id = $xml->show['id'];
Looking at the edit to your question ( is your root element), try this:
$id = $xml->attributes()->id;
OR
$attr = $xml->attributes();
$id = $attr['id'];
OR
$id = $xml['id'];