Hi,
I have found how to manually download CCs from ceskatelevize.cz (Czech TV). Please add this feature to the ceskatelevize.cz plugin! It is trivial for shows/series, where the episode number is in the URL, but movies/one-offs don't seem to be that easy. For shows and series, the algorithm is trivial:
I have found how to manually download CCs from ceskatelevize.cz (Czech TV). Please add this feature to the ceskatelevize.cz plugin! It is trivial for shows/series, where the episode number is in the URL, but movies/one-offs don't seem to be that easy. For shows and series, the algorithm is trivial:
- Check if the "Include closed captions/Stáhnout skryté titulky" tickbox in plugin settings is ticked (blank by default), else break.
- Apply the regular expression replacement below. (This version works on the most common URL format)
FIND: https\:\/\/www\.ceskatelevize\.cz\/porady\/[^\/]*\/(\d{3})(\d*)[\S]*
REPLACE: https\:\/\/imgct\.ceskatelevize\.cz\/cache/data\/ivysilani\/subtitles\/$1/$1$2/sub.vtt
(What the regex does in human language: get the second number in the URL (EpisodeID) and its first three digits (Epi) and apply them to this URL: https://imgct.ceskatelevize.cz/cache/data/ivysilani/subtitles/Epi/EpisodeID/sub.vtt, example: https://www.ceskatelevize.cz/porady/15496675472-prezidentske-volby/223411033110112/ => https://imgct.ceskatelevize.cz/cache/data/ivysilani/subtitles/223/223411033110112/sub.vtt) Note that not all URLs explicitly contain episode IDs, which may need to be retrieved by another function. - If the regex match was successful, add its result as the URL of a new item to downloads list and rename it to Episode name.vtt (same as the downloaded video sans file extension) so that VLC finds it.