**------------------------------------------------------------------------------------------------ * @header_start * WebGrab+Plus ini for grabbing EPG data from TvGuide websites * @Site: dsmart.com.tr Turkish * @MinSWversion: 1.1.1/49 * @Revision 6 - [04/10/2017] Netuddki * - Fixed some errors in scrubbing (dsmart seems to change things on a daily basis) * - Added rating * @Revision 5 - [03/10/2017] Netuddki * - Refined scrubbing. No sorting error anymore * - Added alternate Year, Category, Actors, Director * @Revision 4 - [30/05/2017] Netuddki * - Removed Unnecessary scrubs ("Az Sonra") * - Added missing ")" * @Revision 3 - [29/05/2017] Netuddki * - Fixed duplicate Key * - Refined showsplit * @Revision 2 - [12/05/2017] Blackbear / Netuddki * - Rewrite * @Revision 1 - [24/02/2016] Blackbear199 * - rewrite * @Revision 0 - [24/04/2013] Jan van Straaten * - creation * @Remarks: your_remarks * @header_end **------------------------------------------------------------------------------------------------ site {url=dsmart.com.tr|timezone=UTC|maxdays=7|cultureinfo=tr-TR|charset=UTF-8|titlematchfactor=90} * *site {episodesystem=onscreen} *Enable for Onscreen Episode System site {episodesystem=xmltv_ns} *Enable for xmltv_ns Episode System * * url_index{url|https://www.dsmart.com.tr/actions/schedule?channel_id=|channel|&day=|urldate|} url_index.headers {customheader=Accept-Encoding=gzip,deflate} urldate.format {datestring|yyyy-MM-dd} * index_showsplit.scrub {regex||{"si_traffic_key.*?},||} * scope.range{(splitindex)|end} index_showsplit.modify {sort(ascending,string)} sort_by.scrub {single(target="index_showsplit")|"no"|:|,|,} end_scope * index_showsplit.modify {cleanup} * index_start.scrub {single|"start_date": "|T|Z",|Z",} index_stop.scrub {single|"end_date": "|T|Z",|Z",} index_title.scrub {regex||"program_name":\s"(.*?)",||} index_subtitle.scrub {single(separator=":" exclude=first)|"program_name": "||",} index_title.modify {remove|'index_subtitle'} index_title.modify {remove|:} * index_temp_1.scrub {regex||"synopsis":\s"(.*?)",||} index_temp_2.scrub {regex||"description":\s"(.*?)",||} index_temp_2.modify {addstart("")|'index_temp_1'} index_description.scrub {regex||"extended_synopsis":\s"(.*?)",||} index_description.modify {addstart("")|'index_temp_2'} * index_titleoriginal.scrub {regex||"subject": ".*?\((.*?)\).*?",||} index_titleoriginal.modify {remove(type=regex)|"Dil:.*"} index_temp_3.scrub {regex||"subject": ".*?(?:Oyuncular\|Oyunucular):(.*?)",||} index_actor.modify {substring(type=regex)|'index_temp_3' "(.*?), *\|(.*)"} index_temp_4.scrub {regex||"subject": ".*?Yönetmen:(.*?)(?:Oyuncular\|Oyunucular\|Seslendirenler)||} index_director.modify {substring(type=regex)|'index_temp_4' "(.*?), *\|(.*)"} index_productiondate.scrub {regex||"subject": ".*?(\d{4}).*?",||} * index_category.scrub {regex||"genre_name":\s"(.*?)",||} index_category.scrub {regex||"genre":\s"(.*?)",||} index_category.scrub {regex||"sub_genre_name":\s"(.*?)",||} index_temp_5.scrub {regex||"subject": ".*?Tür:(.*?)Yönetmen:||} index_category.modify {substring(type=regex)|'index_temp_5' "(.*?) - *\|(.*)"} * index_director.scrub {multi(separator=", ")|"director":\s"||",|",} index_director.scrub {multi(separator=", ")|"directors":\s"||",|",} index_actor.scrub {multi(separator=", ")|"actor":\s"||",|",} index_actor.scrub {multi(separator=", ")|"actors":\s"||",|",} * index_subtitles.scrub {regex||"subject": ".*?Altyazı(.*?)\)||} index_subtitles.modify {replace(not "")|'index_subtitles'|true} * index_rating.scrub {regex||"audience_groups":\s(\d+),||} * * index_description.modify {remove(type=regex)|"\(Dil:.*?\)"} ** _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ ** ##### CHANNEL FILE CREATION (only to create the xxx-channel.xml file) ** ** @auto_xml_channel_start *url_index{url|https://www.dsmart.com.tr/actions/channels?page=|subpage|&limit=70} *subpage.format {list|1|2|3} *index_site_id.scrub {regex||"_id": "(.*?)"||} *index_site_channel.scrub {regex||"channel_name": "(.*?)"||} *index_site_channel.modify {cleanup} *index_site_id.modify {cleanup(removeduplicates=equal,100 link="index_site_channel")} ** @auto_xml_channel_end