You are here

public function Crawler::links in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/symfony/dom-crawler/Crawler.php \Symfony\Component\DomCrawler\Crawler::links()

Returns an array of Link objects for the nodes in the list.

Return value

Link[] An array of Link instances

File

vendor/symfony/dom-crawler/Crawler.php, line 718

Class

Crawler
Crawler eases navigation of a list of \DOMElement objects.

Namespace

Symfony\Component\DomCrawler

Code

public function links() {
  $links = array();
  foreach ($this as $node) {
    $links[] = new Link($node, $this->baseHref, 'get');
  }
  return $links;
}