protected function addExtraNamespaces( $nodeset )
    {
        $this->addNamespace( 'hasImages', $nodeset, 'xmlns:image', "http://www.google.com/schemas/sitemap-image/1.1" );
        $this->addNamespace( 'hasVideos', $nodeset, 'xmlns:video', "http://www.google.com/schemas/sitemap-video/1.1" );
        $this->addNamespace( 'hasMobile', $nodeset, 'xmlns:mobile',
            "http://www.google.com/schemas/sitemap-mobile/1.0" );
        $this->addNamespace( 'hasNews', $nodeset, 'xmlns:news', "http://www.google.com/schemas/sitemap-news/0.9" );
    }
protected function addExtraNamespaces( $nodeset )
    {
        $this->addNamespace( 'hasImages', $nodeset, 'xmlns:image', "http://www.google.com/schemas/sitemap-image/1.1" );
        $this->addNamespace( 'hasVideos', $nodeset, 'xmlns:video', "http://www.google.com/schemas/sitemap-video/1.1" );
        $this->addNamespace( 'hasMobile', $nodeset, 'xmlns:mobile',
            "http://www.google.com/schemas/sitemap-mobile/1.0" );
        $this->addNamespace( 'hasNews', $nodeset, 'xmlns:news', "http://www.google.com/schemas/sitemap-news/0.9" );
    }
protected function addExtraNamespaces ( $ nodeset ) { $ this -> addNamespace ( 'hasImages' , $ nodeset , 'xmlns:image' , "http://www.google.com/schemas/sitemap-image/1.1" ) ; $ this -> addNamespace ( 'hasVideos' , $ nodeset , 'xmlns:video' , "http://www.google.com/schemas/sitemap-video/1.1" ) ; $ this -> addNamespace ( 'hasMobile' , $ nodeset , 'xmlns:mobile' , "http://www.google.com/schemas/sitemap-mobile/1.0" ) ; $ this -> addNamespace ( 'hasNews' , $ nodeset , 'xmlns:news' , "http://www.google.com/schemas/sitemap-news/0.9" ) ; }
If we add nodes with special namespaces, we setup a boolean in our iterator classes that switch to true
so we can add the appropriate namespaces to our document.

Ex: an image is added to the document, we set "hasImages" to true so that it's evaluated to true here
and the image namespace is added.

@param \DOMElement $nodeset
If we add nodes with special namespaces we setup a boolean in our iterator classes that switch to true so we can add the appropriate namespaces to our document .