Inicio - Documentación - POM Theme - 12 Recipes - Build a structured content directory

Build a structured content directory

This recipe creates a browsable collection such as people, resources, locations, services, or projects. Editors enter each item once; POM then presents the collection through archive, feed, and single templates with optional Faceted Search.

Model the directory first

List the fields visitors need to see, the properties they filter by, and the relationships editors must maintain.

Use:

  • a custom post type for each repeatable directory entry;
  • taxonomies for shared categories and filterable classifications;
  • custom fields for structured values;
  • the main content editor for long narrative content.

Do not create a taxonomy for a value that is unique to every entry, or a free-text field for a controlled classification.

Create the model

  1. Open Settings → POM Theme → Content model → Post Types.
  2. Add a stable post type slug and customer-facing labels.
  3. Enable its archive and single pages when both are part of the directory.
  4. Open Content model → Taxonomies and attach the required classifications.
  5. Open Content model → Custom fields and add only durable structured fields.
  6. Save Settings → Permalinks after introducing public routes.

Create several representative entries, including missing optional values and long labels, before designing templates.

Build reusable presentation

  1. Create a feed template under Settings → POM Theme → Templates → HMTL templates → Feed HTML templates.
  2. Use the entry's title, permalink, image, excerpt, taxonomy, and supported metadata tags.
  3. Create a single template under Single HTML templates.
  4. Use conditional blocks for genuinely optional fields.
  5. Create or configure the archive and place {{archive_results}} once.
  6. Assign the feed and single templates to the post type.

The feed card should help visitors compare entries; the single template should answer the complete content task.

Add discovery when needed

For a filterable directory, configure Faceted Search with the post type as its query source. Connect facets to the same taxonomies and fields used by editors. Add sorting or pagination only when it supports the directory's browsing task.

Verify the directory

Test the archive, taxonomy archives, direct single URLs, empty values, no results, pagination, filters, browser Back, translated entries, and mobile controls. Confirm unpublished or restricted entries do not appear through another query path.

Related guides