########################################################
# Rojadirecta.eu
########################################################

@IF(@PARAM1@!=Streams)@
####################################################
start=http://rojadirecta.eu
skill=videoTitle

item_infos=<span class="(\d+)".*?<div class="menutitle".*?<span class="t">([^<]+)</span>(.*?)</div>
item_order=id|time.tmp|event.tmp
item_skill=rss

item_info_name=clean.tmp
item_info_from=event.tmp
item_info_convert=replaceRegex('%s','<span class="es">.*?</span>','')
item_info_convert=replace('%s','<span class="en">','')
item_info_convert=replace('%s','</span>','')
item_info_convert=replace('%s',' ()','')
item_info_convert=replace('%s','</time>','')
item_info_convert=replace('%s','<span itemprop="name">','')
item_info_convert=parseText('%s','(.*)<b>\s*(.*?)\s*</b>','sport|event')
item_info_build=%s

item_info_name=time
item_info_from=time.tmp
item_info_convert=replace('%s',';',':')
item_info_convert=offset('%s','+01:00')
item_info_build=%s

item_info_name=title
item_info_from='(' + time + ') ' + sport + ' ' + event
item_info_build=%s

item_info_name=cfg
item_info_from=id
item_info_build=rojadirecta.me.cfg@Streams@%s
item_url_build=%s

title=*UK Unblock*
type=once
cfg=rojadirecta-uk.cfg
url=http://rojadirecta.my.to

@ENDIF@



@IF(@PARAM1@==Streams)@

skill=autoselect
catcher=streams

section=<span class="@PARAM2@".*?</div>\s*</span>\s*</span>

## all but p2p
#item_infos=<tr>\s*<td>NO</td>\s*<td>(?!bwin|bet365)([^<]*)</td>\s*<td>([^<]*)</td>\s*<td>([^<]*).*?</td>\s*<td>([^<]*)</td>\s*<td>(?:<b>)?<a[^>]*href="([^"]+)"
item_infos=<tr>\s*<td>[^<]*</td>\s*<td>(?!bwin|bet365)([^<]*)</td>\s*<td>([^<]*)</td>\s*<td>([^<]*).*?</td>\s*<td>(.*?)</td>\s*<td>(?:<b>)?<a[^>]*href="([^"]+)"
item_order=channel|language.tmp|type|quality.tmp|url.tmp
item_skill=rss

item_info_name=quality
item_info_from=quality.tmp
item_info_convert=ifEmpty('%s','','(%s kbps) ')
item_info_convert=replace('%s','<!--9000-->','')
item_info_convert=replace('%s',' (<span class="es">e</span>stable)','')
item_info_build=%s

item_info_name=language
item_info_from=language.tmp
item_info_convert=ifEmpty('%s','','(%s) ')
item_info_build=%s

item_info_name=alternativeType
item_info_from=url
item_info_convert=parseText('%s','http://www.rojadirecta.eu/(.*)')
item_info_build=Redirect - %s

item_info_name=defType
item_info_from=type || alternativeType
item_info_build=%s

item_info_name=urltmp
item_info_from=url.tmp
item_info_convert=replace('%s','http://','')
item_info_convert=replace('%s','goto/','')
item_info_convert=replace('%s','#www.rojadirecta.eu','')
item_info_convert=replace('%s','#www.rojadirecta.me','')
item_info_build=%s


item_info_name=url
item_info_from='http://' + urltmp
item_info_build=%s
#item_info_build=http://www.rojadirecta.eu/%s

item_info_name=title
item_info_from=channel + ' - ' + quality + language + defType
item_info_build=%s

item_url_build=%s


## catch p2p links directly
########################################################
# SopCast - Videos
########################################################
item_infos=sop://[^:]+:3912/(\d+)
item_order=video
@CATCH(sopcast,video)@

########################################################
# StreamTorrent - Videos
########################################################
item_infos=["'](st://[^"']+)["']
item_order=video

item_info_name=title
item_info_from=video
item_info_build=StreamTorrent - %s

item_info_name=url
item_info_from=video
item_info_build=%s

item_info_name=type
item_info_build=video
item_url_build=%s

@ENDIF@