**------------------------------------------------------------------------------------------------
* @header_start
* WebGrab+Plus ini for grabbing EPG data from TvGuide websites
* @Site: raiplay.it
* @MinSWversion: V2.1.3
* @Revision 3 - [09/09/2017] mat8861 *fix description
* @Revision 2 - [29/08/2017] mat8861 & Blackbear199 *tune up and fixes
* @Revision 1 - [20/06/2017] mat8861 & Blackbear199 *add elements
* @Revision 0 - [24/04/2017] mat8861
* - creation
* @Remarks:
* @header_end
**------------------------------------------------------------------------------------------------
site {url=raiplay.it|timezone=Europe/Rome|maxdays=7|cultureinfo=it-IT|charset=UTF-8|titlematchfactor=0}
site {ratingsystem=IT|episodesystem=onscreen|retry=5}
url_index.headers {customheader=Accept-Encoding=gzip,deflate}
url_index {url|https://www.raiplay.it/guidatv/index.html?canale=|channel|&giorno=|urldate|&new}
urldate.format {datestring|dd-MM-yyyy}
*
index_urlshow {url|https://www.raiplay.it|data-pathdl="||"}
index_urlshow.headers {customheader=Accept-Encoding=gzip,deflate}
*
index_urlsubdetail {url|https://www.raiplay.it|data-href="||">}
index_urlsubdetail.headers {customheader=Accept-Encoding=gzip,deflate}
index_showsplit.scrub {multi|
}
index_urlshow {url|https://www.raiplay.it|data-pathdl="||"}
index_start.scrub {regex||(\d{2}:\d{2})
||}
index_title.scrub {regex||(.*?)
||}
index_title.scrub {cleanup}
index_subtitle.scrub {regex||(.*?)
||}
index_episode.modify {substring(pattern="Stagione 'S1'""Stagione 'S1' Episodio 'E1'""Episodio 'E1'""St'S1' Ep'E1'""S'S1'E'E1'" type=regex)|'index_subtitle' "(?:Stagione\s+\d+\s+)?:Episodio\s+\d+"}
index_subtitle.modify {remove(type=regex)|(?:Stagione\s+\d+\s+)?Episodio\s+\d+} *disable to keep Season/Episode in subtitle
index_subtitle.modify {cleanup}
index_description.scrub {regex||([^/]*)
||}
index_description.modify {cleanup}
index_category.modify {substring(type=regex)|'index_description' "(^.*?)\s-\s"}
index_description.modify {remove|'index_category' - }
index_description.modify {cleanup}
*
title.scrub {single|||
|}
title.modify {cleanup(tags="<"">")}
title.modify {addstart("")|'index_title'}
subtitle.scrub {single|}
description.scrub {single(includeblock=1)|||
}
description.modify {cleanup(removeduplicates span=2 keeplast)}
description.modify {cleanup(tags="<"">")}
description.modify {cleanup}
director.scrub {single(exclude="AA VV" separator=", ""," max=3)||- Regia|
}
presenter.scrub {single(separator=", ")|
|}
productiondate.scrub {regex||- (\d{4})
||}
country.scrub {regex||||}
actor.scrub {single(separator=", ""," max=4)|}
actor.modify {cleanup(tags="<"">")}
actor.modify {cleanup}
*
subdetail_episode.scrub {multi(include="St ""Ep ")||||
}
subdetail_episode.modify {replace|\|| }
subdetail_episode.modify {replace|St |Stagione }
subdetail_episode.modify {replace|Ep |Episodio }
subdetail_subtitle.modify {remove(type=regex)|(?:St\s+\d+\s+)?Ep\s+\d+}
subdetail_description.scrub {single|||
}
subdetail_description.modify {cleanup(removeduplicates span=2 keeplast)}
subdetail_description.modify {cleanup}
*
*
*
** _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
** ##### CHANNEL FILE CREATION (only to create the xxx-channel.xml file)
**
** @auto_xml_channel_start
*url_index {url|https://www.raiplay.it/guidatv/}
*index_site_id.scrub {multi|- }
*index_site_channel.scrub {regex||
- }
*scope.range {(channellist)|end}
*index_site_id.modify {cleanup(removeduplicates=equal,100 link="index_site_channel")}
** @auto_xml_channel_end