forked from SilentButeo2/webgrabplus-siteinipack
/
horizon.tv.ini
170 lines (168 loc) · 8.27 KB
/
horizon.tv.ini
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
**------------------------------------------------------------------------------------------------
* @header_start
* WebGrab+Plus ini for grabbing EPG data from TvGuide websites
* @Site: horizon.tv
* @MinSWversion: V2.1.1
* @Revision 10 - [24/02/2019] DeBaschdi
* - modified Episodesystem for Kodi usage
* @Revision 9 - [02/02/2019] DeBaschdi
* - modified (lang-attributes) for german usage. needed for incremental grabbing
* @Revision 8 - [17/01/2019] DeBaschdi
* - fix for episode "pattern/patten"
* @Revision 7 - [15/01/2019] DeBaschdi
* - fix for sub-title "parentld"
* @Revision 6 - [25/07/2017] Blackbear199
* - added lang attrubute for different countries
* @Revision 5 - [24/03/2017] Blackbear199
* - episode fix
* @Revision 4 - [17/01/2017] Blackbear199
* - fix for linux users using php script due to https issues
* @Revision 3 - [24/08/2016] Blackbear199
* - combined all countries into single ini
* - added italy
* @Revision 2 - [07/07/2016] Blackbear199
* - changed api address to one that doesnt change
* @Revision 1 - [19/06/2016] Blackbear199
* - api change,category small fix
* @Revision 0 - [29/04/2016] Blackbear199
* - creation
* @Remarks:
* hozizon.tv all countries.Netherlands,Switzerland,France,Italy,Germany,Poland,Ireland,Czech Republic,Austria,Romania,Hungary,Slovakia
* windows and linux users may need to use different url_index,index_urlshow,url_index(channell.xml creation).be sure to enable correct one.disable the other.
* @header_end
**------------------------------------------------------------------------------------------------
*
site {url=horizon.tv|timezone=UTC|maxdays=7|cultureinfo=de-DE|charset=utf-8|titlematchfactor=90|episodesystem=xmltv_ns}
site {retry=<retry time-out="30">4</retry>}
*
url_index{url|https://web-api.horizon.tv/oesp/api/##country##/web/programschedules/|urldate|/|subpage|} *mono > 5.0.0.1
*url_index{url|http://127.0.0.1/horizon_tv.php?country=##country##&date=|urldate|&subpage=|subpage|&reqtype=1} * linux/windows php
url_index.headers {customheader=Accept-Encoding=gzip,deflate}
url_index.headers {accept=application/json|contenttype=application/json}
url_index.headers {customheader=Accept-Encoding=gzip,deflate}
*
urldate.format {datestring|yyyyMMdd}
subpage.format{list|1|2|3|4}
*
scope.range{(urlindex)|end}
index_variable_element.modify {substring(type=regex)|'config_site_id' "^(.*?)_"}
url_index.modify {replace|##country##|'index_variable_element'}
end_scope
*
global_temp_1.modify {substring(type=regex)|'config_site_id' "_(\d+)__"}
index_urlchannellogo.modify {substring(type=regex)|'config_site_id' "__(.*?)$"}
index_showsplit.scrub {multi|"o":"'global_temp_1'",|{|}|]}}
index_showsplit.modify {cleanup(removeduplicates=equal,100)}
*
* lang configuration
global_temp_2.modify {set|'index_variable_element'}
global_temp_2.modify {replace|NL/nld|nl}
global_temp_2.modify {replace|CH/deu|de}
global_temp_2.modify {replace|CH/fra|fr}
global_temp_2.modify {replace|CH/ita|it}
global_temp_2.modify {replace|DE/deu|de}
global_temp_2.modify {replace|PL/pol|pl}
global_temp_2.modify {replace|IE/eng|en}
global_temp_2.modify {replace|CZ/ces|cz}
global_temp_2.modify {replace|AT/deu|de}
global_temp_2.modify {replace|HU/hun|hu}
*
index_start.scrub {single|"s":||,|,}
index_stop.scrub {single|"e":||,|,}
index_title.scrub {single|"t":"||",|",}
*
index_urlshow {url|https://web-api.horizon.tv/oesp/api/'index_variable_element'/web/listings/|"i":"||"|"} *mono > 5.0.0.1
*index_urlshow {url|http://127.0.0.1/horizon_tv.php?country='index_variable_element'&reqtype=2&showid=|"i":"||"|"} * linux/windows php
index_urlshow.headers {customheader=Accept-Encoding=gzip,deflate}
*
index_title.modify {addend('global_temp_2' not "de")|(lang='global_temp_2')}
*
title.scrub {single|"title":"||",|",}
subtitle.scrub {regex||"secondaryTitle":"(.*?)"[,\}]||}
subtitle.modify {clear('title')}
description.scrub {single|"longDescription":"||",|",}
director.scrub {single(separator="\",\"")|"directors":["||"],|"],}
actor.scrub {single(separator="\",\"")|"cast":["||"],|"],}
*
category.scrub {multi|"categories":[|"title":"|",|}]}
category.scrub {single|"medium":"||",|",}
category.modify {remove|TV}
category.modify {remove|Series}
category.modify {replace|/|\|}
category.modify {cleanup(style=name)}
category.modify {cleanup(removeduplicates=equal,100)}
*
*temp_1.scrub {single|"seriesEpisodeNumber":"||"|"}
*temp_1.modify {clear(> "1000")}
*temp_1.modify {addstart(not "")|E}
*temp_2.scrub {single|"seriesNumber":"||"|"}
*temp_2.modify {clear(> "10000")}
*temp_2.modify {addstart(not "")|S}
*temp_1.modify {addstart('temp_2' not "")|'temp_2' }
*episode.modify {addstart('temp_1' not "" patten="S'S1'E'E1'""S'S1'""E'E1'")|'temp_1'}
temp_3.scrub {single|"seriesNumber":"||"|"}
temp_3.modify {clear(> "10000")}
temp_3.modify {calculate(not="" format=F0)|1 -}
temp_4.scrub {single|"seriesEpisodeNumber":"||"|"}
temp_4.modify {clear(> "1000")}
temp_4.modify {calculate(not="" format=F0)|1 -}
episode.modify {clear}
episode.modify {addend('temp_3' not="")|'temp_3'}
episode.modify {addend|.}
episode.modify {addend('temp_4' not="")|'temp_4'}
episode.modify {addend|.}
episode.modify {clear(="..")}
*
productiondate.scrub {single|"year":"||"|"}
temp_3.modify {substring(type=regex)|'config_site_id' "^(\w{2})\/"}
rating.scrub {single|"parentalRating":"||"|"}
rating.modify {clear("0")}
rating.modify {addend(notnull)|(system=FSK)}
*
starrating.modify {substring(type=regex)|'description' "IMDb.*"}
description.modify {replace|\|| }
description.modify {remove|'starrating'}
description.modify {cleanup(style=jsondecode)}
starrating.modify {substring(type=regex)|"\d\.\d\/10"}
starrating.modify {addend(notnull)|(system=IMDb)}
showicon.scrub {single|"tva-boxcover"|"url":"|"|}}
*
*title.modify {addend('global_temp_2' not "de")|(lang='global_temp_2')}
*subtitle.modify {addend(notnull)|(lang='global_temp_2')}
*description.modify {addend(notnull)|(lang='global_temp_2')}
*category.modify {addend(notnull)|(lang='global_temp_2')}
** _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
* ##### CHANNEL FILE CREATION (only to create the xxx-channel.xml file)
*
** @auto_xml_channel_start
*url_index {url|https://web-api.horizon.tv/oesp/api/|subpage|&personalised=false} *mono > 5.0.0.1
*url_index.modify {replace|_|/web/channels?sort=channelNumber&byLocationId=} *mono > 5.0.0.1
**url_index{url|http://127.0.0.1/horizon_tv.php?chxmldata=|subpage|&reqtype=3} * linux/windows php
*subpage.format {list|NL/nld_24443942973|CH/deu_21656615412|CH/fra_21657127006|CH/ita_21657126954|DE/deu_97245734974|PL/pol_239100967286|IE/eng_6651943228|CZ/ces_667808295264|AT/deu_554823207312|RO/ron_552441895089|HU/hun_552442407296|SK/slk_604944423340}
*index_site_id.scrub {|}
*index_temp_9.modify {set|NL/nld\|CH/deu\|CH/fra\|CH/ita\|DE/deu\|PL/pol\|IE/eng\|CZ/ces\|AT/deu\|RO/ron\|HU/hun\|SK/slk}
*index_temp_1.modify {set|0}
*index_temp_8.scrub {multi|{"entryCount"|||}
*loop{(each "index_temp_7" in 'index_temp_8')|end}
*index_temp_2.modify {substring(type=element)|'index_temp_9' 'index_temp_1' 1}
*index_temp_6.modify {substring(type=regex)|'index_temp_7' "\{\"station\":\{\"id\":\"(.*?subChannels)"}
*index_temp_6.modify {replace(type=regex)|(\",\"countryCode\".*?150.*?\"url\":\")|__}
*index_temp_6.modify {remove(type=regex)|.png(.*?subChannels)|__}
*index_temp_6.modify {remove(type=regex)|(\",\"countryCode\".*?subChannels)|__}
*index_temp_6.modify {addstart|'index_temp_2'_}
*index_temp_6.modify {replace|\||##}
*index_temp_5.modify {substring(type=regex)|'index_temp_7' "\{\"station\":\{\"id\":.*?\"title\":\"([^\"]*)\","}
*index_temp_5.modify {replace|\||##}
*index_temp_4.modify {addend|'index_temp_6'##}
*index_temp_3.modify {addend|'index_temp_5'##}
*index_temp_1.modify {calculate(format=F0)|1 +}
*end_loop
*index_site_id.modify {addstart|'index_temp_4'}
*index_site_id.modify {replace|##|\|}
*index_site_id.modify {remove(type=element)|-1 1}
*index_site_channel.modify {addstart|'index_temp_3'}
*index_site_channel.modify {replace|##|\|}
*index_site_channel.modify {remove(type=element)|-1 1}
*index_site_channel.modify {remove(type=regex)|[^\w\s]}
*index_site_id.modify {cleanup(removeduplicates=equal,100 link="index_site_channel")}
** @auto_xml_channel_end