Extend PHP base classes for XML processing, error handling and conviance