Answer the question
In order to leave comments, you need to log in
How to access a specific element by number in phpQuery?
phpQuery finds multiple entries. You can iterate through them with foreach. But how to access a specific record?
Answer the question
In order to leave comments, you need to log in
I accessed it like this:
$links = $pq->find('a');
$three = $links->eq(3);
$links = $pq->find('a');
//Выведет 3ю найденную ссылку
var_dump($links[2]);
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question