Ha, I did it!
Instead of
$pa = new PageArray();
$value = $pages->find( "title%=$q" );
$pa->import( $pages->find( "template=abc, …|…|…=$value" ) );
$pa->import( $pages->find( "template=abc, title%=$q" ) );
I wrote this
$pa = $pages->find( "template=abc, bla1.title|bla2.title|bla3.title|…|title%=$q, limit=4" );
I don’t search for the page references but for the titles of the page references with ".title". Works like a charm.
Hey, thanks for the welcome.
Now I get it. $page->rootParent by itself outputs an ID and therefor you can check if a page is the current one. Rather trivial, but I really didn’t see it. Thanks.