85 lines
4.3 KiB
INI
Executable File
85 lines
4.3 KiB
INI
Executable File
**------------------------------------------------------------------------------------------------
|
||
* @header_start
|
||
* WebGrab+Plus ini for grabbing EPG data from TvGuide websites
|
||
* @Site: programatv.bg
|
||
* @MinSWversion: V1.57
|
||
* @Revision 0 - [13/11/2016] Blackbear199
|
||
* - creation
|
||
* @Remarks:
|
||
* @header_end
|
||
**------------------------------------------------------------------------------------------------
|
||
site {url=programatv.bg|timezone=Europe/Sofia|maxdays=7|cultureinfo=bg-BG|charset=UTF-8|titlematchfactor=90}
|
||
site {ratingsystem=FSK|episodesystem=onscreen}
|
||
*
|
||
url_index{url|http://programatv.bg/tv-programm-data?date=|urldate|&SenderGroups=1&senderpart=##page##}
|
||
url_index.headers {customheader=Accept-Encoding=gzip,deflate}
|
||
*
|
||
urldate.format {datestring|MM-dd-yyyy}
|
||
*
|
||
scope.range{(urlindex)|end}
|
||
index_temp_1.modify {substring(type=regex)|'config_site_id' "^([^#]*)##"}
|
||
url_index.modify {replace|##page##|'index_temp_1'}
|
||
end_scope
|
||
*
|
||
index_variable_element.modify {substring(type=regex)|'config_site_id' "##(.*)$"}
|
||
index_showsplit.scrub {multi|<td class="channel" data-sender="'index_variable_element'">|<a |</a>|</td>}
|
||
*
|
||
index_urlshow {url|http://programatv.bg|href="||"|"}
|
||
index_urlshow.headers {customheader=Accept-Encoding=gzip,deflate}
|
||
*
|
||
index_start.scrub {single| data-start="||"|"}
|
||
index_stop.scrub {single| data-end="||"|"}
|
||
index_title.scrub {single|<h2 class="titleAudition ">||</h2>|</h2>}
|
||
*
|
||
index_title.modify {cleanup(tags="<span""</span>")}
|
||
*
|
||
title.scrub {single|<h1 class="pull-left" itemprop="name">||</h1>|</h1>}
|
||
titleoriginal.scrub {single|<div class="amaz">|var name = "|"|</script>}
|
||
subtitle.scrub {single|<strong>Подзаглавие: </strong>||</span>|</span>}
|
||
description.scrub {single|<p class="info" itemprop="description">||</p>|</p>}
|
||
director.scrub {multi(includeblock=""director"")|<li data-actor=|title="|"|</li>}
|
||
actor.scrub {multi(includeblock=""actor"")|<li data-actor=|title="|"|</li>}
|
||
writer.scrub {multi(includeblock=""author"")|<li data-actor=|itemprop="name">|<br />|</li>}
|
||
rating.scrub {single|<label class="info">|FSK |</span>|</label>}
|
||
category.scrub {single|<label class="info" itemprop="genre">||</label>|</label>}
|
||
productiondate.scrub {single|<i class="fa fa-calendar-o"></i> <span>||</span>|</span>}
|
||
country.scrub {single|<i class="fa fa-globe"></i><span>||</span>|</span>}
|
||
starrating.scrub {single|<div class="pull-right stars"|<meta itemprop="ratingValue" content="|">|</div>}
|
||
episode.scrub {single(pattern="E:'E1'")|<h1 class="pull-left" itemprop="name">|<small>(|)</small>|</h1>}
|
||
showicon.scrub {single|<div class="photoevent">|src="|"|</div>}
|
||
*
|
||
title.modify {cleanup(tags="<span""</span>")}
|
||
titleoriginal.modify {clear('title')}
|
||
category.modify {cleanup(tags="<"">")}
|
||
starrating.modify {calculate(not "" format=F1)}
|
||
*
|
||
** _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
|
||
** ##### CHANNEL FILE CREATION (only to create the xxx-channel.xml file)
|
||
**
|
||
** @auto_xml_channel_start
|
||
*url_index{url|http://programatv.bg/tv-programm-data?SenderGroups=1&date=|urldate|&senderpart=|subpage|}
|
||
*subpage.format {list(format=D0 step=4 count=9)|0}
|
||
*scope.range {(channellist)|end}
|
||
*index_site_id.scrub {multi|<table class="programTable"||</table>|</table>}
|
||
*index_temp_9.modify {set|0\|4\|8\|12\|16\|20\|24\|28\|32}
|
||
*index_temp_3.modify {set|0}
|
||
*loop{(each "index_temp_8" in 'index_site_id')|end}
|
||
*index_temp_7.modify {substring(type=element)|'index_temp_9' 'index_temp_3' 1}
|
||
*index_temp_6.modify {substring(type=regex)|'index_temp_8' "<td class=\"channelPrime\" data-sender=\"([^\"]*)\">"}
|
||
*index_temp_6.modify {addstart|'index_temp_7'##}
|
||
*index_temp_6.modify {replace|\||###}
|
||
*index_temp_1.modify {addend|'index_temp_6'###}
|
||
*index_temp_5.modify {substring(type=regex)|'index_temp_8' "<div class=\"channelName\">[^<]*<span>([^<]*)<\/span>"}
|
||
*index_temp_5.modify {replace|\||###}
|
||
*index_temp_2.modify {addend|'index_temp_5'###}
|
||
*index_temp_3.modify {calculate(format=F0)|1 +}
|
||
*end_loop
|
||
*index_site_id.modify {addstart|'index_temp_1'}
|
||
*index_site_id.modify {replace|###|\|}
|
||
*index_site_id.modify {remove(type=element)|-1 1}
|
||
*index_site_channel.modify {addstart|'index_temp_2'}
|
||
*index_site_channel.modify {replace|###|\|}
|
||
*index_site_channel.modify {remove(type=element)|-1 1}
|
||
*end_scope
|
||
** @auto_xml_channel_end
|