Cast as whatever type you want (and makes sense...). By concatenating, you're implicitly casting to string, so
$value = (string) $xml->someNode->innerNode;
2.1m questions
2.1m answers
60 comments
57.0k users