**------------------------------------------------------------------------------------------------ * @header_start * WebGrab+Plus ini for grabbing EPG data from TvGuide websites * @Site: tvguide.co.uk * @MinSWversion: V1.1.1/54.1 * none * @Revision 13 - [05/02/2015] Francis De Paemeleere * change to xmltv_ns episode system * @Revision 12 - [02/12/2014] Francis De Paemeleere * remove user specific modifications * removed duplicate shows issue * add showicon * @Revision 11 - [30/11/2014] Ruby * Description scrub modification + new Detailpage layout: index_urlshow modification + remake details scrub * @Revision 10 - [08/09/2014] Jan van Straaten * complete remake: Single channel index page now available, loadcookie not required anymore * @Revision 9 - [04/04/2014] Willy De Wilde * additional separator in start * @Revision 8 - [20/03/2014] Willy De Wilde * Website change * @Revision 7 - [24/02/2014] Willy De Wilde * Use of main page - channel pages do not grab anymore * @Revision 6 - [16/12/2013] Francis De Paemeleere * adapted to site changes in the indexdetail pages * @Revision 5 - [17/11/2013] Jan van Straaten * adapted to site changes in the showdetail pages * @Revision 4 - [15/01/2013] Francis De Paemeleere * added new auto_xml_channel * @Revision 3 - [30/11/2011] Jan van Straaten * make producer multi value * @Revision 2 - [] * correction in description, adapted for 1.0.7 * @Revision 1 - [] * added producer, writer, episode , improved description, adapted for 1.0.5 * @Remarks: * none * @header_end **------------------------------------------------------------------------------------------------ site {url=tvguide.co.uk|timezone=Europe/London|maxdays=7|cultureinfo=en-US|charset=UTF-8|titlematchfactor=50|nopageoverlaps|episodesystem=xmltv_ns} url_index{url|http://my.tvguide.co.uk/channellisting.asp?ch=|channel|&cTime=|urldate| 5:00:00 AM&thisTime=&thisDay=} url_index.headers {customheader=Accept-Encoding=gzip,deflate} urldate.format {datestring|MM/dd/yyyy} *index_showsplit.scrub {regex||(\d{1,2}\:\d{2}.{1}m
.+?.+?.+?)||} index_showsplit.scrub {regex||(]*background-image[^>]*>.+?
.+?)||} scope.range {(splitindex)|end} index_showsplit.modify {cleanup(removeduplicates=equal span=1)} * remove any duplicate show end_scope index_start.scrub {regex||(\d{1,2}\:\d{2}(?:am\|pm))||} index_title.scrub {regex||(.+?)
||} ***Productiondate: index_productiondate.scrub {single||(|)|
} * in title index_title.modify {remove| ('index_productiondate')} index_title.modify {cleanup} ***Category: index_category.scrub {regex||Category
(.*?)
||} index_category.modify {remove|/Factual Topics} index_category.modify {remove|/Folkloric} index_category.modify {remove|/Environment} index_category.modify {replace|/|\|} ***Episode: index_episode.scrub {single|||
|} index_episode.modify {remove| } index_episode.modify {replace|Season |S} index_episode.modify {replace|Episode |E} index_episode.modify {replace| of |/} index_episode.modify {remove| of} * convert the onscreen episode info to xmltv_ns index_temp_1.modify {clear} index_temp_2.modify {clear} index_temp_3.modify {clear} index_temp_4.modify {clear} index_temp_1.modify {substring(type=regex)|'index_episode' "S(\d*)"} index_temp_2.modify {substring(type=regex)|'index_episode' "E(\d*)"} index_temp_3.modify {substring(type=regex)|'index_episode' "S\d*/(\d*)"} index_temp_4.modify {substring(type=regex)|'index_episode' "E\d*/(\d*)"} * index_temp_1 = season * index_temp_2 = episode * index_temp_3 = number of seasons * index_temp_4 = number of episodes index_temp_1.modify {calculate(not="" format=F0)|1 -} index_temp_2.modify {calculate(not="" format=F0)|1 -} index_episode.modify {clear} index_episode.modify {addend('index_temp_1' not="")|'index_temp_1'} index_episode.modify {addend('index_temp_3' not="")|/'index_temp_3'} index_episode.modify {addend|.} index_episode.modify {addend('index_temp_2' not="")|'index_temp_2'} index_episode.modify {addend('index_temp_4' not="")|/'index_temp_4'} index_episode.modify {addend|.} index_episode.modify {clear(="..")} ***Subtitle: index_subtitle.scrub {regex||(.*?)||} index_subtitle.modify {remove|Category } ***Description: index_description.scrub {regex||(.*?)
||} index_description.modify {substring(type=element)|0 1} index_description.modify {addend(not"")|.} ***Starrtaing: index_starrating.scrub {single|Rating
|">|
|} index_starrating.modify {addend(not"")| /10} ***Subtitles: index_subtitles.scrub {regex||\(Subtitles\)||} index_subtitles.modify {substring(type=element)|0 1} * more than one, keep only one index_subtitles.modify {replace(not "")|'index_subtitles'|true} ***Showicon: index_showicon.scrub {regex||]*background-image[^>]*url\(([^)]*[^\/])\)||} index_urlshow.scrub {regex|| index_urlshow.modify {substring(type=element)|0 1} index_urlshow.headers {customheader=Accept-Encoding=gzip,deflate} title.scrub {single|
||
|} title.modify {cleanup(tags="<"">")} title.modify {remove|('index_productiondate')} title.modify {cleanup} *productiondate.scrub {single|
|(|)|
} * in title *category.scrub {single|

Genre

|>||} ***Rating: (old scrub) *New rating not available yet! *rating.scrub {single|Certificate ||

|} *rating.modify {cleanup(tags="<"">")} *rating.modify {addstart(not"")|// PG} *rating.modify {addend(not"")|+ //} *rating.modify {replace|PGPG|PG} ***Crew: ??? temp_1.scrub {single(separator="
")|
||
|} temp_1.modify {replace|
| (} temp_1.modify {remove|
} temp_1.modify {replace|
|)} temp_1.modify {addend(not"")|,} temp_1.modify {cleanup} temp_1.modify {replace|\||####} temp_1.modify {addstart(not"")|####} ***Cast & Crew: ??? temp_4.scrub {multi(excludeblock="
    ")|
    |
  • |
  • |
} temp_4.modify {replace|
| (} temp_4.modify {replace|
|)} temp_4.modify {cleanup(tags="<"">")} temp_4.modify {addend(not"")|,} temp_4.modify {cleanup} temp_4.modify {replace|\||####} temp_4.modify {addstart(not"")|####} ***Actor: actor.scrub {multi|} actor.modify {replace|
|(} actor.modify {remove|
} actor.modify {remove|>} actor.modify {replace|
|)} actor.modify {cleanup(tags="<"">")} actor.modify {addend(not"")|,} actor.modify {cleanup} actor.modify {replace|\||####} actor.modify {addstart(not"")|####} actor.modify {addend('temp_1' not"")|'temp_1'} actor.modify {addend('temp_4' not"")|'temp_4'} actor.modify {replace|####|\|} actor.modify {remove|####} temp_2.modify {calculate(type=element format=F0)|'actor' #} loop {('temp_2' > "0" max=50)|end} temp_2.modify {calculate(format=F0)|1 -} temp_3.modify {substring(type=element)|'actor' 'temp_2' 1} * the credit to inspect presenter.modify {addstart('temp_3' ~ "Presenter")|####'temp_3'} * actor.modify {remove('temp_3' ~ "Presenter" type=element)|'actor' 'temp_2' 1} presenter.modify {addstart('temp_3' ~ "Host")|####'temp_3'} * actor.modify {remove('temp_3' ~ "Host" type=element)|'actor' 'temp_2' 1} commentator.modify {addstart('temp_3' ~ "Guest")|####'temp_3'} * ***Commentator used for Guest, Contributor, Contestant, Panellist, Performer*** actor.modify {remove('temp_3' ~ "Guest" type=element)|'actor' 'temp_2' 1} commentator.modify {addstart('temp_3' ~ "Contributor")|####'temp_3'} * actor.modify {remove('temp_3' ~ "Contributor" type=element)|'actor' 'temp_2' 1} commentator.modify {addstart('temp_3' ~ "Contestant")|####'temp_3'} * actor.modify {remove('temp_3' ~ "Contestant" type=element)|'actor' 'temp_2' 1} commentator.modify {addstart('temp_3' ~ "Performer")|####'temp_3'} * actor.modify {remove('temp_3' ~ "Performer" type=element)|'actor' 'temp_2' 1} commentator.modify {addstart('temp_3' ~ "Panellist")|####'temp_3'} * actor.modify {remove('temp_3' ~ "Panellist" type=element)|'actor' 'temp_2' 1} composer.modify {addstart('temp_3' ~ "Reporter")|####'temp_3'} * ***Composer used for Reporter, Narrator, Anchor*** actor.modify {remove('temp_3' ~ "Reporter" type=element)|'actor' 'temp_2' 1} composer.modify {addstart('temp_3' ~ "Narrator")|####'temp_3'} * actor.modify {remove('temp_3' ~ "Narrator" type=element)|'actor' 'temp_2' 1} composer.modify {addstart('temp_3' ~ "Anchor")|####'temp_3'} * actor.modify {remove('temp_3' ~ "Anchor" type=element)|'actor' 'temp_2' 1} director.modify {addstart('temp_3' ~ "Director")|####'temp_3'} * actor.modify {remove('temp_3' ~ "Director" type=element)|'actor' 'temp_2' 1} producer.modify {addstart('temp_3' ~ "Producer")|####'temp_3'} * actor.modify {remove('temp_3' ~ "Producer" type=element)|'actor' 'temp_2' 1} writer.modify {addstart('temp_3' ~ "Writer")|####'temp_3'} * actor.modify {remove('temp_3' ~ "Writer" type=element)|'actor' 'temp_2' 1} writer.modify {addstart('temp_3' ~ "Editor")|####'temp_3'} * actor.modify {remove('temp_3' ~ "Editor" type=element)|'actor' 'temp_2' 1} end_loop temp_1.modify {clear} temp_2.modify {clear} temp_3.modify {clear} temp_4.modify {clear} actor.modify {replace|####|\|} * make multi presenter.modify {replace|####|\|} * make multi commentator.modify {replace|####|\|} * make multi composer.modify {replace|####|\|} * make multi director.modify {replace|####|\|} * make multi producer.modify {replace|####|\|} * make multi writer.modify {replace|####|\|} * make multi actor.modify {cleanup(removeduplicates)} presenter.modify {cleanup(removeduplicates)} commentator.modify {cleanup(removeduplicates)} composer.modify {cleanup(removeduplicates)} director.modify {cleanup(removeduplicates)} producer.modify {cleanup(removeduplicates)} writer.modify {cleanup(removeduplicates)} commentator.modify {remove| (Guest)} commentator.modify {remove| (Performer)} commentator.modify {remove| (Panellist)} commentator.modify {remove| (Contestant)} commentator.modify {remove| (Contributor)} presenter.modify {remove| (Presenter)} presenter.modify {remove| (Host)} director.modify {remove| (Director)} producer.modify {remove| (Producer)} actor.modify {remove| (Actor)} writer.modify {remove| (Writer)} ***Description: description.scrub {single|

Plot Synopsis

|
|
|} ** _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ ** ##### CHANNEL FILE CREATION (only to create the xxx-channel.xml file) ** ** @auto_xml_channel_start *url_index{url|http://www.tvguide.co.uk/} *index_site_channel.scrub {multi(debug)||