src/XML/DOM/Parser.php
protected function loadXml( $xml )
	{
		$xsv	= new XML_DOM_SyntaxValidator;
		if( !$xsv->validate( $xml ) )
			throw new Exception( "XML Document is not valid:".$xsv->getErrors() );
		$this->document	= $xsv->getDocument();
		$this->clearOptions();
		foreach( $this->attributes as $attribute )
			if( isset( $this->document->$attribute ) )
				$this->setOption( $attribute, $this->document->$attribute );
	}
protected function loadXml( $xml )
	{
		$xsv	= new XML_DOM_SyntaxValidator;
		if( !$xsv->validate( $xml ) )
			throw new Exception( "XML Document is not valid:".$xsv->getErrors() );
		$this->document	= $xsv->getDocument();
		$this->clearOptions();
		foreach( $this->attributes as $attribute )
			if( isset( $this->document->$attribute ) )
				$this->setOption( $attribute, $this->document->$attribute );
	}
protected function loadXml ( $ xml ) { $ xsv = new XML_DOM_SyntaxValidator ; if ( ! $ xsv -> validate ( $ xml ) ) throw new Exception ( "XML Document is not valid:" . $ xsv -> getErrors ( ) ) ; $ this -> document = $ xsv -> getDocument ( ) ; $ this -> clearOptions ( ) ; foreach ( $ this -> attributes as $ attribute ) if ( isset ( $ this -> document -> $ attribute ) ) $ this -> setOption ( $ attribute , $ this -> document -> $ attribute ) ; }
Loads XML String into DOM Document Object before parsing.
@access		public
@param		string		$xml			XML to be parsed
@return		void
Loads XML String into DOM Document Object before parsing .