How to build a large music catalog with Views and custom search. A case study.
Imagine a music catalog site with thousands of music pieces to listen and download. What is a must-have for such a site to fulfill its role effectively? You guessed it: a friendly search engine. A custom search which responds your individual preferences and searching criteria. While having such a convenient search seems to be obvious from a site visitor’s perspective, implementing a custom search in WordPress can be a challenge, especially if you are not a PHP guru.
Today David Das, a music composer, producer, and songwriter from Los Angeles reveals how he created his huge portfolio site with the Views plugin. Stay with us and take this unique opportunity to read how a composer for such famous clients like 20th Century Fox, NBC, Coca Cola, and Disney worked with the Toolset plugin to end up with a fully searchable music directory integrated with e-commerce.
About the project
A large music catalog site for a composer, producer and songwriter to showcase his music and offer it for sale and licensing.
The main challenges of the project
The goal was to create a music catalog in WordPress:
- allowing the presentation and management of thousands of pieces of music,
- with audio support,
- working hand-in-hand with a CSV importer/exporter,
- integrated with e-commerce plugins,
- well-structured and easily searchable for a site visitor.
About the author
David Das is a composer, producer, and songwriter. Born in England, he has lived all over the world, but has spent most of his life in the USA, and is based in Los Angeles, the heart of the film, television, and music industry. He writes a large amount of music in many different stylistic genres for various film, TV, and commercial projects, and was looking for a way to be able to showcase the music as well as offer it for sale and licensing.
David created the daviddas.com web site himself, with the help of a commercial WordPress template and Toolset plugins. When asked how he came to be a music composer who can also work on web sites, no doubt a rare combination, he explains:
“I have a background in some basic programming. I grew up with a Mac in the house, learned BASIC as a kid, learned HTML in the 1990’s, and have been using WordPress for the past several years, so in the course of working with WordPress have figured out some of the basics of CSS and PHP to be able to modify code written by other people, though I’m not advanced enough to write my own.”
The road leads to Toolset – the beginnings
David found Toolset during a web search as he was looking for a solution that helped him not only create custom post types but filter them well. He basically wanted to create an online database for thousands of pieces of music, with both audio and e-commerce support, and have the database be readily accessible and easily update-able.
“I came across Views first, and that really unlocked a major piece of the puzzle for me. I knew of other custom post type plugins, but I really needed significant help with the management and sorting of them.” explains David.
There are a number of commercial music licensing database solutions out there — services like SourceAudio, LicenseQuote, YouLicense, and so on. All of these had elements he liked and disliked, but they either had missing features or their price was too high.
“I also consulted some professional WordPress developers, asking them to custom-program an engine for me. The estimates ranged from a few thousand dollars up to $20,000. Yet I knew that even in the core of WordPress itself, there were sorting mechanisms for posts, so I was really looking for a tool that could offer that and extend WordPress’s existing capabilities, without having to reinvent the wheel.”
“I watched the Views demo videos and immediately saw that it had the potential to do the job. Seeing that they even offered a return policy, it was a no-brainer to try it out, and I found I was able to build the core of the engine fairly easily by following the demos.”
How the core engine of the site was built
Graphic design came last
David’s site no doubt catches the eye and stands out from other music catalogs because of its unique, individual design.
For example, take the ‘Watch and Listen’ page: a masonry-based gallery filled with covers of projects he has worked on. The images are magnetic, the layout is responsive, and the black background seems to add more magic to the site.
When it came to the database of music, found on the Music Catalog page, it had to be designed from scratch. But there were two distinct major challenges: the database functionality, and the graphic design/layout.
“I started working on the database functionality first. I already had a good idea of the data that needed to be displayed – things like cover art, title, artist, description, metatags, buy buttons, and so on – but I wasn’t sure how to design a sortable, searchable engine for it, so I tackled that problem with Views first, knowing that if I could solve that, then skinning it in a GUI would be an easier task.”
The main showcase of David’s usage of Toolset is the music cataloguing aspect. Every piece of music in his database has:
- a title,
- link to a preview audio file,
- a link to a full-length file that the customer can buy
- cover image,
- legal information (writer, publisher, licensing parameters, etc.),
- and more hidden fields,
and everything needs to be searchable and sortable.
When we say “database,” we aren’t referring to the WordPress database in SQL. David actually manages his music in a standard Excel spreadsheet, but more on that in a moment.
When asked if it was hard to come up with the structure for the music catalog, David says it wasn’t hard at all:
“I was familiar with dozens of other music library engines. I knew there was a core set of information that was needed for every piece of music: title, description, audio links, image links, and so on. Organizing all of that in Excel made it very easy to input and also to keep updated.”
Now let’s see how it was implemented in WordPress.
David used regular WordPress posts to manage his music tracks, which is the simplest solution and works well in this case. Using WordPress’s native categories and tags allowed David to use two different, independent ways to categorize music:
- WordPress’s categories were used for the musical genres (e.g. pop, jazz, orchestral, etc.)
- WordPress’s tags were used for individual words that could be associated with each piece of music (e.g. happy, fast, driving, emotional, epic, cinematic, female vocal, etc.)
Visitors to the site can search through all the music using either approach, or both combined, for example, a pop song that is happy, or an orchestral piece that is inspirational.
All additional data associated with a single piece of music (artist, cover image, etc.) were added as custom fields, which are natively supported by WordPress.
Let’s see how it looks like both from the front-end and WordPress back-end.
Custom Search – the heart of music catalog site
When you look at David’s WordPress dashboard and go to Views -> Views section, you may be surprised to see only one View; it’s called ‘Music Catalog’ and it is the home page for the collection of music:
This is the custom search View behind the site’s Music Catalog home page. To end up with a results as shown below, you start by creating a ‘Display the results as a custom search’ View.
Compare the two pictures below to see how it looks both from the front-end and back-end.
And here’s what the Views Filter section looks like. If you are new to Views Custom search, here are a few words of explanation:
- in the Views Query section you choose what to display
- in the Filter section you add the terms you want to filter by.
In addition, David then offers a Detail page. If someone clicks on a title of a particular song, they are taken to a new page which is specific to that one song. One example URL would be:
daviddas.com/disappear-full-mix/ This is done in Views by a Content Template.
Why CSV import support was a must-have
David’s artistic and creative output is tremendous, and is reflected in the huge quantity of database data. Because of the large amount of data, and because the ability to edit it in batch is very important, he wanted to manage his central database in Excel:
“Sometimes I have to add or update many pieces of music at once, so it’s much easier to do it in Excel than it is in the WordPress backend. (I know there are ways to do it in SQL but I’m not that technical and I’d be afraid of breaking something!) So I found a great CSV importing plugin that can take my Excel spreadsheet and instantly import every field for every song, including both the standard fields and the custom fields. I can erase and re-upload this database anytime I need to add or modify any information.”
While implementing Views, he ended up using the free WP Ultimate CSV Importer plugin* which does everything he needs it to.
*For CSV data importing on our wp-types.com site, we recommend using the CSV importer plugin, which works in a similar way. Read the How to Import CSV data into WordPress CSV file tutorial to find out more.
On the Music Catalog page you can see all the blue Digital Download buttons. The same buttons are also available on the detail page for each piece of music (for example: http://daviddas.com/disappear-full-mix/). To implement e-commerce, David used the Easy Digital Downloads plugin.
In his master Excel spreadsheet, he assigns every one of his music pieces a unique SKU number (it’s a custom field, not visible to the user). This SKU number is uploaded as a custom field in WordPress, then within Views, he uses a shortcode that offers a ‘Buy Now’ button, and he has Views call for the correct SKU number. This enables David to offer every piece for instant one-click sale via PayPal:
So to summarize this site’s construction, it looks like this:
- Install the Views to handle your custom search without PHP coding,
- populate WordPress with your Excel data via an importer plugin,
- then integrate with PayPal
and you are all set.
They say “Everything is hard before it is easy” and David’s case confirms this. He did run into obstacles while working on both the CSV handling and e-commerce. Sometimes the plugins would do part of what he needed them to do but not everything, and other plugins were buggy. “It took months to get all that ironed out,” he says.
“Working with Views also took some time, to get the custom search working properly, and then especially, working on the user interface, finding a home for all the elements and making it look cohesive,” David summaries.
Toolset is not a magic wand. You don’t just wave it and things happen. It’s a tool that lets you construct simple and complex web applications that can handle both small and large amounts of data. The Views plugin also integrates very well with other WordPress plugins, since it uses shortcodes and the standard WordPress table.
David is still not sure if he would recommend someone like he follow in his footsteps because, as he says, he honestly spent months solving problems, posting questions in forums, waiting for answers that a more experienced programmer might have finished the whole job in a week.
But in the end it did get done.
A note from the editor
We got a lot of submissions in response to our case studies invitation. Seeing a music composer among our Toolset users caught my attention. I admit, I not only got away from my work duties while visiting David’s site and listened to the music he writes, but I also took the opportunity to ask about the process of licensing David’s music for a commercial use.David explained to me that buying a single track for casual use for 99 cents is exactly the same as buying a track from iTunes or any other digital retailer: the user is buying a song for private recreational listening.
But if a piece of music is to be used in a media project (for example, a commercial, TV show, video, even if for non-profit use), then a sync license is required. One client may call and request one of his music pieces as a background for a YouTube video, while another client may want to use it in a corporate video that’s being shown to hundreds of employees. Another may want to use it in a broadcast ad, or TV show, or film. Another client may request exclusivity (meaning, no one else may use that piece of music for a period of time).
Each use varies widely, and is worth anywhere from $50 to more than $10,000! Because of this, it was important to build an engine that could show the music, help people find the right music, then allow them to purchase it, or reach out for a licensing agreement. “Much of this music has found its way into TV shows and films, and that’s always the most thrilling outcome for me,” said David.
Thank you, David for revealing these details and for the chance to interview you. It was a real pleasure to work on this study with you.