private function getSubmitStateNodeList() : Generator
    {
        $xpath    = new DOMXPath($this->document);
        $nodeList = $xpath->query('//input[@type="submit"] | //button[@type="submit"]');

        /** @var DOMElement $node */
        foreach ($nodeList as $node) {
            $name = $node->getAttribute('name');
            if (! $name) {
                // At least a name is needed to submit a value.
                continue;
            }

            yield $name;
        }
    }
private function getSubmitStateNodeList() : Generator
    {
        $xpath    = new DOMXPath($this->document);
        $nodeList = $xpath->query('//input[@type="submit"] | //button[@type="submit"]');

        /** @var DOMElement $node */
        foreach ($nodeList as $node) {
            $name = $node->getAttribute('name');
            if (! $name) {
                // At least a name is needed to submit a value.
                continue;
            }

            yield $name;
        }
    }
private function getSubmitStateNodeList ( ) : Generator { $ xpath = new DOMXPath ( $ this -> document ) ; $ nodeList = $ xpath -> query ( '//input[@type="submit"] | //button[@type="submit"]' ) ; /** @var DOMElement $node */ foreach ( $ nodeList as $ node ) { $ name = $ node -> getAttribute ( 'name' ) ; if ( ! $ name ) { // At least a name is needed to submit a value. continue ; } yield $ name ; } }
Get names of available named submit elements
Get names of available named submit elements