I've never used ProcessWire before. I took a quick look at the API documentation, but wasn't able to find anything that met my needs.
Any help would be greatly appreciated. I've attached a screenshot of one of the template pages in question. I didn't write it, but perhaps it could be helpful.