Extension for php SimpleXml