You are here

date/time

5 posts / 0 new
Last post
banusev
Offline
Donator
Joined: 5 years
Last seen: 6 months
date/time

I scrub start time from index in format 20190713142500 but I get error

[ Debug ] Elements , type single applied
[ Debug ] ----------begin--element----------
[ Debug ] 20190713145500
[ Debug ] ----------end----element----------
[ Debug ] Converted to:
01.1.1900 00:00:00
[ Debug ] Converted to:
01.1.1900 00:00:00
[ Debug ] skipped : show that happened before 'today' @ 01/01/1900 00:00
[ Debug ] Debugging information SiteIni

Anybody knows how to read this format in proper way

Blackbear199
Online
Blackbear199's picture
WG++ Team memberDonator
Joined: 9 years
Last seen: 19 sec

add pattern="yyyyMMddHHmmss" argument,see the manual for more details.

banusev
Offline
Donator
Joined: 5 years
Last seen: 6 months

Did not work that way but I figure out, This is what I did and it works:

index_start.scrub {single(debug)|"start":"|| +0200|}
index_start.modify {set(debug, pattern="yyyyMMddHHmmss")|'index_start'}

index_stop.scrub {single(debug)|","stop":"|| +0200|}
index_stop.modify {set(debug, pattern="yyyyMMddHHmmss")|'index_stop'}

But I have another problem now with url_index, in the url contain start and stop date in the same format start/20190720235959/stop/20190730235959

How do I modify that to be start now and stop + 10 days

Blackbear199
Online
Blackbear199's picture
WG++ Team memberDonator
Joined: 9 years
Last seen: 19 sec

index_start.scrub {single(debug pattern="yyyyMMddHHmmss")|"start":"|| +0200|}
shud do the same thing but only uses a single line.

for this..
start/20190720235959/stop/20190730235959

on site {xx} line set maxdays=10.1

urldate.format {datestring|yyyyMMdd}

start/|urldate|235959/stop/##end_date##235959

scope.range{(urlindex)|end}
global_temp_1.modify {calculate(format=F0)|'config_timespan_days'}
global_temp_1.modify {calculate(format=date,yyyyMMdd)|'urldate' 'global_temp_1':0:0 +}
url_index.modify {replace|##end_date##|'global_temp_1'}
end_scope

or as u wanted a fixed 10 days..

scope.range{(urlindex)|end}
global_temp_1.modify {calculate(format=date,yyyyMMdd)|'urldate' 10:0:0 +}
url_index.modify {replace|##end_date##|'global_temp_1'}
end_scope

I prefer the first way because say u only wanted 7 days epg.
this was gets the timespan value from your wg config.xml and gets the number of days requested.
why grab 10 days of epg to keep only 7(in this example).

banusev
Offline
Donator
Joined: 5 years
Last seen: 6 months

Thanks a lot for your help
I finish ini file but any idea how to share it in the member area so other people can have it?

Log in or register to post comments

Brought to you by Jan van Straaten

Program Development - Jan van Straaten ------- Web design - Francis De Paemeleere
Supported by: servercare.nl