FieldtypePagesSelectorQuery by alevine

This module allows you to defined a Pages selector query ($pages>find()) as a field and attach it to a template. The results of the query (PageArray) are accessed like any other page field, $page->myQuery

This module allows you to defined a Pages selector query ($pages>find()) as a field and attach it to a template. The results of the query (PageArray) are accessed like any other page field, $page->myQuery

I was trying to solve the problem of running a query as a field, and this is the result.

I started with Hanna text, but that didn't quite get me all the way. Then I tried just a Concat field, and that didn't get me all the way.

I modified the Concat fieldtype for my solution. I had a need to dynamically pull Pages that were cross-referenced back:
Product as a Page
Photo Pages with a multi-Page Select field that referenced Product (A photo could represent 1+ Products)


I wanted a ->photos field from Product that was updated dynamically according to what Photo entries were currently in place, and I didn't want copy/pasted code, and I wanted the selectors to be easily modifiable from the admin screens.

Install and use modules at your own risk. Always have a site and database backup before installing new modules.

Latest news

  • ProcessWire Weekly #559
    The 559th issue of ProcessWire Weekly brings in all the latest news from the ProcessWire community. Modules, sites, and more. Read on!
    Weekly.pw / 25 January 2025
  • ProcessWire 3.0.244 new main/master version
    ProcessWire 3.0.244 is our newest main/master/stable version. It's been more than a year in the making and is packed with tons of new features, issue fixes, optimizations and more. This post covers all the details.
    Blog / 18 January 2025
  • Subscribe to weekly ProcessWire news

“Indeed, if ProcessWire can be considered as a CMS in its own right, it also offers all the advantages of a CMF (Content Management Framework). Unlike other solutions, the programmer is not forced to follow the proposed model and can integrate his/her ways of doing things.” —Guy Verville, Spiria Digital Inc.