frjo / hugo-theme-zen

A fast and clean Hugo base theme with css-grid and Hugo pipes support.
https://zen-demo.xdeb.org/
GNU General Public License v2.0
264 stars 75 forks source link

Media player in the podcast page doesn't work #103

Closed metasikander closed 12 months ago

metasikander commented 1 year ago

Not sure if there's some issue with the theme, or something I have done, but the player at https://antihashed.xyz/podcast/episode_020/ doesn't work. It wont play.
There's also a link to the file, but doesn't go to the file in a web-player or downloads the file, just takes you back to the main page.
Is there something i should do differently, or are some changes needed in the code.

metasikander commented 1 year ago

code for the page: https://github.com/metasikander/antihashed

frjo commented 1 year ago

Yes, it was a bug in the podcast partial. I had fixed it in the feed some time back but forgot to to it in the partial as well.

https://github.com/frjo/hugo-theme-zen/blob/dab1fb45da60c917f3b9f6c4e56bbf6803a3ea63/layouts/partials/podcast.html#L3

If you can confirm that it works I will make a new release with the fix.

frjo commented 1 year ago

Also noticed that your config.yaml have issues. You seem to have copied all the params straight from the README. This gives you bit of a mess.

Trim the conf down to something like this, setting only the values you want to change:

baseurl: "https://antihashed.xyz/"
title: "Antihashed Podcast"
theme: "zen"
languageCode: "en-GB"       # Set your language code (only needed for none multilingual sites).

params:
  cookieConsent: false       # Show cookie consent form, default false.
  contact: "email@antihashed.xyz"
  description: "Two grumpy men talk about bitcoin and starcraft"           # Set site description, used in meta tags and JSON-LD
  feedlinks: false           # Show feed links in the footer.
  footer: "RSS Feed address: https://antihashed.xyz/podcast/index.xml"
  logoHight: 200            # Set logo height, defaults to none.
  logoWidth: 200            # Set logo width, defaults to none.
  menuInHeader: true        # Move the main menu to the header, default false.
  mobileMenu: true          # Turn on a mobile menu on small screens, default false.
  poweredby: true           # Show powered by hugo in footer
  relatedposts: true        # Show related posts under a "See also" section, default false.
  sidebar: true             # Show a sidebar to the right, default false.
  submitted: true           # Show author and date information for a post.

  podcast:
    title: "Antihashed"                 # * Feed title, defaults to site title (iTunes).
    description: "Two grumpy men talk about bitcoin and starcraft"           # * Feed description/summary, defaults to  site description (iTunes).
    image:  logo.png                # * Feed image, place inside assets directory (iTunes).
    category:
      name: "Technology"                # * Feed category (iTunes).
    explicit: true    # Feed explicit setting, default to false (iTunes).
    author: "Constant and Fiatjaf"                # Feed author (iTunes).
    owner:
      name: "Constant and Fiatjaf"               # Feed owner name (iTunes).
      email: "email@antihashed.xyz"               # Feed owner e-mail (iTunes).
    type: episodic   # Podcast type, defaults to episodic (iTunes).
    cdn:  "https://antihashed.us-east-1.linodeobjects.com"                  # CDN url, no slash on end (https://cdn.example.org).
    local: false            # Are the audio files local (true) or remote (false), default to true.
metasikander commented 12 months ago

Thank you. The player now works, and the cleanup helped!