I'm loading an xml file comming from a comercial software. If I do print_r($xml) I get something like this: 
SimpleXMLElement Object (
 [records] => SimpleXMLElement Object (
     [record] => SimpleXMLElement Object (
         [database] => SomeData
         [ref-type] => SomeData
         [contributors] => SimpleXMLElement Object (
             [authors] => SimpleXMLElement Object (
                 [author] => Array (
                     [0] => SomeData
                     [1] => SomeData
                     [2] => SomeData
                     [3] => SomeData
                     [4] => SomeData
                )
            )
        )
    )
)
I'm extracting desired data with this
$MyNewArray['DataBase'] = (string) $xml->records->record->database;
But can't get to the data when there is an hyphen (there are several fields with an hyphen):
$MyNewArray['ReferenceType'] = (string) $xml->records->record->ref-type;
Does anybody know a solution?
