Documentation
Site building

Fields and display

Choose image media types, group the forms into tabs, add fields, show the audio player, and override templates.

Podcasts and episodes are Drupal entities with their own field settings, separate from content types.

EntitySettings page
PodcastStructure → Podcasts (/admin/structure/podcast)
Podcast EpisodeStructure → Podcast Episode (/admin/structure/podcast-episode)

With Drupal's Field UI module enabled, each settings page has the usual Manage fields, Manage form display, and Manage display tabs. Opening the settings page needs Administer podcast settings or Administer podcast episode settings. The tabs need Field UI's permissions, such as Podcast: Administer fields and Podcast Episode: Administer display.

Images

The images of podcasts, episodes, people and chapters are media items. The forms use the Media Library, so editors pick an existing image or upload a new one.

Choose the media types at Structure → Podcasts (/admin/structure/podcast), under Images:

  • Media types: the media types editors can pick from. Leave all unchecked to allow every media type with an image source, such as core's Image. For other media types, such as remote video, the feed uses the media item's thumbnail.
  • Media type of uploaded chapter images: shown when more than one media type has an image source.

Uploading images needs at least one media type with an image source. If your site has none, add one at Structure → Media types with the Image source.

Chapter images are picked by name. Install Media Library Form Element to pick them in the Media Library instead.

drush updatedb moved existing image fields to media items.

Form tabs

With the Field Group module enabled, the podcast and episode forms group their optional fields into vertical tabs, such as Feed settings, People and Feed ownership and moves for podcasts, and Numbering, Media and accessibility, Chapters and People for episodes. The main fields, such as the title, image, audio file and shownotes, stay above the tabs.

The tabs ship as form display configuration that is installed with Field Group. If you already saved Manage form display for podcasts or episodes, your display is kept; add the groups there yourself.

Add a field

  1. Open Manage fields on the Podcast or Podcast Episode settings page.
  2. Click Create a new field and configure it as you would on a content type.
  3. Arrange it on Manage form display and Manage display.

The built-in fields, such as Title, Audio File, and Shownotes, are defined by the module. You can arrange, hide, and format most of them, but not delete them or change their storage settings.

A new field does not appear in the RSS feed automatically. To use it for a feed tag, see Customize the feed.

Show the audio player and shownotes

On a new site, an episode's page shows its label, author, dates, and keywords, but not the audio or the shownotes. To show them:

  1. Open Structure → Podcast Episode → Manage display (/admin/structure/podcast-episode/display).
  2. Move Audio File and Shownotes from the Disabled section into the content region.
  3. Set the Audio File format to Audio, Drupal's built-in HTML5 player.
  4. Optionally, move Transcripts too and set its format to Generic file to link the transcript files.
  5. Click Save.

If you use episode pages, open Manage display for the Podcast Episode Page content type and set the Podcast Episode field's format to Rendered entity. The page then shows the episode with the display configured above.

The Download Tracker URL formatter outputs the tracked URL as plain text, not a player. Plays in the website's player are therefore not counted unless a custom template feeds the tracked URL to the player. See Analytics.

Override templates

The module ships two templates in its templates directory:

TemplateRenders
podcast.html.twigA podcast page
podcast-episode.html.twigAn episode page

To change the markup, copy a template into your theme's templates directory, edit it, and clear caches with drush cr. Both templates print content, which holds the fields in the order set on Manage display. The module provides no template suggestions per view mode, so one template applies to every display.

The feed template is covered in Customize the feed.