public function getElementsByName($name)
    {
        $found = array();
        foreach ($this->getRecursiveIterator() as $element) {
            if ($element->getName() == $name) {
                $found[] = $element;
            }
        }
        return $found;
    }
public function getElementsByName($name)
    {
        $found = array();
        foreach ($this->getRecursiveIterator() as $element) {
            if ($element->getName() == $name) {
                $found[] = $element;
            }
        }
        return $found;
    }
public function getElementsByName ( $ name ) { $ found = array ( ) ; foreach ( $ this -> getRecursiveIterator ( ) as $ element ) { if ( $ element -> getName ( ) == $ name ) { $ found [ ] = $ element ; } } return $ found ; }
Returns an array of elements which name corresponds to element

@param    string  Elements name to find
@return   array
Returns an array of elements which name corresponds to element