MP3 Audio Player
Documentation
Search for articles about the Audio Player and WordPress Theme
Table of contents

How to use Filters Widget using ACF

Welcome to this tutorial on how to add filters to your audio player and display them effectively. Filters can help your audience easily navigate and find the audio they want. In this step-by-step guide, we’ll show you how to create a new filter category and add options to it, then seamlessly integrate it into your audio player for a better user experience.

Understanding Posts and Filtering

In WordPress, content is organized into “posts.” This includes everything from blog articles to individual tracks in your playlist. The MP3 Audio Player Pro utilizes this structure to manage and display your audio content. To leverage WordPress’s filtering capabilities effectively, it’s crucial to organize your audio tracks appropriately.

One Track Per Post!

Assigning one track per post is more than just a recommendation—it’s a strategy for making the most out of WordPress’s filtering system. When you filter content on your site, you’re actually filtering posts based on their attributes, like categories, tags, and custom fields.

This approach ensures that you’re effectively filtering posts according to specific attributes (e.g., categories, tags, custom fields, etc.). Our player is designed to aggregate and display multiple “posts.” For instance, if your site hosts 10 different posts, each with one track, the player will showcase those 10 tracks. Conversely, if you have 1 post containing 10 tracks, the player will display a total of 10 tracks. However, filtering might not work as expected because WordPress’s filtering system is designed to work at the post level, not on individual tracks within posts.

Filtering track’s metadata or ID3 Tags ?

It’s important to understand that track metadata cannot be filtered straight out of the box. You can only filter based on the post’s custom fields, categories or tags.

We recommend using the plugin ACF (Advanced Custom Fields) to create these fields and not rely on the track’s ID3 tags. Filtering based on track metadata is not feasible due to the sheer volume of tracks and potential inconsistencies in metadata, such as slight variations in artist names. This limitation is in place to maintain performance and user experience.

Wait, I have over 1000 tracks! Do I have to create 1000 individual posts manually ?

Fortunately, the answer is no. You can streamline the process by using the PLAYLIST BULK IMPORTER, accessible via WP-Admin > MP3 Player > Tools. This will allow you to automatically generate posts—be they for products or any kind of audio posts—from the MP3 files you choose.

After initiating the bulk creation, the newly formed posts will appear in draft mode. This setup allows you to conveniently review and publish them en masse.

For those looking to apply custom field values across multiple posts efficiently, the following plugins come highly recommended, significantly easing the management of your audio content:

→ Admin Columns Pro
→ Product Bulk Editor for WooCommerce

How to create custom fields & use filter widgets ?

The video below shows you how to create custom fields with ACF, and how to use filters in the player.

Frequently Asked Questions #

Q: Where can i find the player ID’s for the filters?
A: You can set an ID on the player widget here: https://drops.sonaar.io/i/jGH86v

Updated on March 27, 2024
Was this article helpful?
Still Stuck?
We can help.