Introduction

As a senior WordPress developer specialized in Divi, building a scalable catalog website for sports activities in Ibiza can be an exciting challenge. The goal is to create a platform that effectively displays and filters a wide array of activities, supporting a user-friendly experience.

Site Structure and Custom Post Types

To begin with, setting up a custom post type labeled “deportes” (sports) is essential. This will facilitate a unique data structure for sports activities, with a slug of /deportes/. The single view of each activity will be accessible at /deportes/{slug}/. Each post type supports essential features like title, editor, excerpt, and thumbnail.

Configuration of Filters and Taxonomies

We will define several hierarchical taxonomies: nivel (level), temporada (season), zona (area), and categoria_deporte (sport category). All taxonomies will be set with show_in_rest=true: allowing easy integration with the REST API. Moreover, using Advanced Custom Fields (ACF), we can add specific fields like precio_desde (price from) and duracion (duration), enhancing the information available for each sport activity.

Implementing SEO-Friendly Filters

The filters on the main archive page can be constructed with a simple form using the GET method. The search functionality allows queries by title, with additional filters for levels, seasons, areas, and categories. This structure ensures that our filters work effectively without reliance on premium plugins. An example URL structure post-filtering might appear as /deportes/?q=surf.

This approach not only promotes scalability for up to 100 activities but also ensures a modern aesthetic and usability, reflecting a modern-day sports activity catalog.