src/voku/helper/SimpleHtmlDom.php 1 location
|
@@ 388-397 (lines=10) @@
|
385 |
|
* |
386 |
|
* @return SimpleHtmlDomInterface|SimpleHtmlDomInterface[]|SimpleHtmlDomNodeInterface|null |
387 |
|
*/ |
388 |
|
public function childNodes(int $idx = -1) |
389 |
|
{ |
390 |
|
$nodeList = $this->getIterator(); |
391 |
|
|
392 |
|
if ($idx === -1) { |
393 |
|
return $nodeList; |
394 |
|
} |
395 |
|
|
396 |
|
return $nodeList[$idx] ?? null; |
397 |
|
} |
398 |
|
|
399 |
|
/** |
400 |
|
* Find nodes with a CSS selector. |
src/voku/helper/SimpleXmlDom.php 1 location
|
@@ 361-370 (lines=10) @@
|
358 |
|
* |
359 |
|
* @return SimpleXmlDomInterface|SimpleXmlDomInterface[]|SimpleXmlDomNodeInterface<SimpleXmlDomInterface>|null |
360 |
|
*/ |
361 |
|
public function childNodes(int $idx = -1) |
362 |
|
{ |
363 |
|
$nodeList = $this->getIterator(); |
364 |
|
|
365 |
|
if ($idx === -1) { |
366 |
|
return $nodeList; |
367 |
|
} |
368 |
|
|
369 |
|
return $nodeList[$idx] ?? null; |
370 |
|
} |
371 |
|
|
372 |
|
/** |
373 |
|
* Find nodes with a CSS selector. |