LogoLogo
ForumCodeDonate
  • Introduction
    • About
    • Release / Change Log
  • Installation
    • Requirements
    • Tuners
    • Linux
    • Virtualisation - Proxmox
    • Docker
    • NAS
    • Android
  • SETUP
    • Stages
    • Concepts
    • Muxes/Scan Files
      • Scan Files
      • Using w_scan Scan Files
  • CONFIGURATION
    • Concepts
    • Electronic Program Guide
    • Digital Video Recorder
    • Web User Interface Customisation
      • Theme
      • Date/Time Format
  • HTTPS access via Reverse Proxy
  • APPENDICES
    • FAQ
    • CLI Commands
    • Debugging
  • Development
    • Compiling
      • Compiling TVH with VAAPI Support
        • for Lubuntu 24.04
        • for Lubuntu 22.04
        • Level 2
    • HTSP
      • General
      • HTSMSG Binary Format
      • Communication
      • Client to Server (RPC) methods
      • Server to Client methods
      • Protocol Changes
      • HTTP Proxy Examples
    • JSON API
      • API Description
        • Common Parameters
        • Access
        • Bouquet
        • Caclient
        • Channel
        • Codec
        • Config
        • DVR
        • EPG
        • EPGgrab
        • ESfilter
        • idnode
        • Input
        • intlconv/charsets
        • Language
        • MPEGts
        • Profile
        • RatingLabel
        • Raw
        • Satip
        • Service
        • Status
        • Timeshift
        • Tvhlog
      • Examples
      • Other Functions
      • WebSocket
    • Object Class Relationships
    • Testing Tuners Using Files
    • Translations
    • Programmers Translation Workflow
    • XMLTV
      • Input
        • Recognised Tags/Attributes
        • Episode Numbering
      • Output
    • Object ID Representation
    • WebUI Help Content Workflow
    • Random Notes
  • Creating a Mux Dump
  • WIP
    • Release / Change Log Mockup
  • Release / Change Log 2
Powered by GitBook

© Tvheadend 2006-2024

On this page

Was this helpful?

Export as PDF
  1. Development
  2. XMLTV
  3. Input

Episode Numbering

TVH accepts three episode numbering schemes via XMLTV.

  • onscreen

  • dd_progid

  • xmltv_ns

<episode-num system="onscreen">S01E01</episode-num>

Set the 'episodeOnscreen' property of the EPG event to the value provided. TVH treats this value as free-form plain-text and no additional series or episode parsing is performed.

Note: If an 'episode-num' tag exists with a 'system' attribute set to 'onscreen', the tag's value will override the EPG event's 'episodeOnscreen' property regardless of the series or episode numbers parsed from other 'episode-num' tags. However, the other properties, for example 'seasonNumber' are set correctly. The 'onscreen' override occurs regardless of the sequence of the 'episode-num' tags.

<episode-num system="dd_progid">SH00012345.0000</episode-num>

Set the 'serieslinkUri' property to "ddprogid://xmltv/SH00012345.0000". No additional series or episode parsing is performed.

<episode-num system="dd_progid">EP00012345.0001</episode-num>

Set the 'episodeUri' property to "ddprogid://xmltv/EP00012345.0001". Set the 'serieslinkUri' property to "ddprogid://xmltv/EP00012345". Set the 'episodeNumber' property to 1. Set the 'episodeOnscreen' property to "e01".

<episode-num system="xmltv_ns">1/16.3/25.1/2</episode-num>

Set the 'seasonNumber' property to 2. Set the 'seasonCount' property to 16. Set the 'episodeNumber' property to 4. Set the 'episodeCount' property to 25. Set the 'partNumber' property to 2. Set the 'partCount' property to 2. Set the 'episodeOnscreen' property to "s02.e04".

Note: In a number pair separated by a slash, the first number is zero-based and the second number is 1-based. Episode 8 of 12 is represented by '7/12'. Series/episode/part numbers are always zero-based when appearing alone.

<episode-num system="xmltv_ns">1/15.3/24</episode-num>

Set the 'seasonNumber' property to 2. Set the 'seasonCount' property to 15. Set the 'episodeNumber' property to 4. Set the 'episodeCount' property to 24. Set the 'episodeOnscreen' property to "s02.e04".

<episode-num system="xmltv_ns">2.4</episode-num>

Set the 'seasonNumber' property to 3. Set the 'episodeNumber' property to 5. Set the 'episodeOnscreen' property to "s03.e05".

Note: The property names in the above examples refer to the HTML/JSON API.

PreviousRecognised Tags/AttributesNextOutput

Last updated 1 year ago

Was this helpful?

More details on the XMLTV format can be found here: and here: .

https://wiki.xmltv.org/index.php/XMLTVFormat
https://github.com/XMLTV/xmltv/blob/master/xmltv.dtd