I have problems with webparser where log says:
regexp matching error (-1)
RSS feed of interest:
http://feeds.bbci.co.uk/news/world/rss.xml
is it something to do with the square parantheses [ ] in the regexp?
this regexp used to work but it seems BBC recently changed their xml feed structure by adding the [CDATA[ ]] thingy. So i tried to fix it, but its not working.
My code (stripped down):
Code: Select all
[Variables]
; BBCitemsect contains the regular expression for parsing 1 section/headline. multiple of instances of this variable are used to obtain all headlines from the RSS feed. see [RSS] section below
; (?=.*<item>) look ahead assertions used because not always >=24 items in RSS feed.
BBCitemsect=(?(?=.*<item>)<item>.*<title><![CDATA[(.*)]]></title>.*<description><![CDATA[(.*)]]></description>.*<link>(.*)</link>.*<pubDate>(.*)</pubDate>.*</item>.*)
[RSS]
Measure=Plugin
Plugin=WebParser
Url=http://feeds.bbci.co.uk/news/world/rss.xml
RegExp=(?siU)#BBCitemsect##BBCitemsect##BBCitemsect##BBCitemsect##BBCitemsect##BBCitemsect##BBCitemsect##BBCitemsect##BBCitemsect##BBCitemsect##BBCitemsect##BBCitemsect##BBCitemsect##BBCitemsect##BBCitemsect##BBCitemsect##BBCitemsect##BBCitemsect##BBCitemsect##BBCitemsect##BBCitemsect##BBCitemsect##BBCitemsect##BBCitemsect#
UpdateRate=300
;------
[RSS1title]
Measure = Plugin
Plugin=WebParser
Url = [RSS]
StringIndex =1
Substitute = #Substitute#
[RSS1descript]
Measure = Plugin
Plugin=WebParser
Url = [RSS]
StringIndex =2
Substitute = #Substitute#
[RSS1link]
Measure = Plugin
Plugin=WebParser
Url = [RSS]
StringIndex =3
Substitute = #Substitute#
[RSS1date]
Measure = Plugin
Plugin=WebParser
Url = [RSS]
StringIndex =4
Substitute = #Substitute#
;------
[RSS2title]
Measure = Plugin
Plugin=WebParser
Url = [RSS]
StringIndex =5
Substitute = #Substitute#
[RSS2descript]
Measure = Plugin
Plugin=WebParser
Url = [RSS]
StringIndex =6
Substitute = #Substitute#
[RSS2link]
Measure = Plugin
Plugin=WebParser
Url = [RSS]
StringIndex =7
Substitute = #Substitute#
[RSS2date]
Measure = Plugin
Plugin=WebParser
Url = [RSS]
StringIndex =8
Substitute = #Substitute#
;------
[RSS3title]
Measure = Plugin
Plugin=WebParser
Url = [RSS]
StringIndex =9
Substitute = #Substitute#
[RSS3descript]
Measure = Plugin
Plugin=WebParser
Url = [RSS]
StringIndex =10
Substitute = #Substitute#
[RSS3link]
Measure = Plugin
Plugin=WebParser
Url = [RSS]
StringIndex =11
Substitute = #Substitute#
[RSS3date]
Measure = Plugin
Plugin=WebParser
Url = [RSS]
StringIndex =12
Substitute = #Substitute#
[RSS1linkbutton]
meter = image
x = 0
y = 28r
h = #clickhovbarH#
w = #seplinwidth#
solidcolor =0,0,0,1
mouseoveraction = [!SetOption #CURRENTSECTION# solidcolor #hoverbarcolor#][!Updatemeter #CURRENTSECTION#][!Redraw]
mouseleaveaction = [!SetOption #CURRENTSECTION# solidcolor 0,0,0,1][!Updatemeter #CURRENTSECTION# ][!Redraw]
leftmousedownaction = [!SetOption #CURRENTSECTION# solidcolor #clickbarcolor#][!Updatemeter #CURRENTSECTION#][!Redraw]
leftmouseupaction = [!SetOption #CURRENTSECTION# solidcolor #hoverbarcolor#][!Updatemeter #CURRENTSECTION#][!Redraw]["#eVIEWER#" "[RSS1link]]"
hidden=0
[RSS1String]
Meter = STRING
MeasureName = RSS1title
X = 15
Y = #relbartext#
FontColor = #txtcolor#
FontSize = #txtsize#
FontFace = #txtfont#
StringEffect = #txteffect#
FontEffectColor = #txteffectcolor#
AntiAlias = 0
Prefix = #dotpt#
ClipString = #CPS#
ClipStringW = #CPSW#
ClipStringH = #CPSH#
hidden=0
;------
[RSS2linkbutton]
meter = image
x = 0
y = 28r
h = #clickhovbarH#
w = #seplinwidth#
solidcolor =0,0,0,1
mouseoveraction = [!SetOption #CURRENTSECTION# solidcolor #hoverbarcolor#][!Updatemeter #CURRENTSECTION#][!Redraw]
mouseleaveaction = [!SetOption #CURRENTSECTION# solidcolor 0,0,0,1][!Updatemeter #CURRENTSECTION# ][!Redraw]
leftmousedownaction = [!SetOption #CURRENTSECTION# solidcolor #clickbarcolor#][!Updatemeter #CURRENTSECTION#][!Redraw]
leftmouseupaction = [!SetOption #CURRENTSECTION# solidcolor #hoverbarcolor#][!Updatemeter #CURRENTSECTION#][!Redraw]["#eVIEWER#" "[RSS2link]]"
hidden=0
[RSS2String]
Meter = STRING
MeasureName = RSS2title
X = 15
Y = #relbartext#
FontColor = #txtcolor#
FontSize = #txtsize#
FontFace = #txtfont#
StringEffect = #txteffect#
FontEffectColor = #txteffectcolor#
AntiAlias = 0
Prefix = #dotpt#
ClipString = #CPS#
ClipStringW = #CPSW#
ClipStringH = #CPSH#
hidden=0
;------
[RSS3linkbutton]
meter = image
x = 0
y = 28r
h = #clickhovbarH#
w = #seplinwidth#
solidcolor =0,0,0,1
mouseoveraction = [!SetOption #CURRENTSECTION# solidcolor #hoverbarcolor#][!Updatemeter #CURRENTSECTION#][!Redraw]
mouseleaveaction = [!SetOption #CURRENTSECTION# solidcolor 0,0,0,1][!Updatemeter #CURRENTSECTION# ][!Redraw]
leftmousedownaction = [!SetOption #CURRENTSECTION# solidcolor #clickbarcolor#][!Updatemeter #CURRENTSECTION#][!Redraw]
leftmouseupaction = [!SetOption #CURRENTSECTION# solidcolor #hoverbarcolor#][!Updatemeter #CURRENTSECTION#][!Redraw]["#eVIEWER#" "[RSS3link]]"
hidden=0
[RSS3String]
Meter = STRING
MeasureName = RSS3title
X = 15
Y = #relbartext#
FontColor = #txtcolor#
FontSize = #txtsize#
FontFace = #txtfont#
StringEffect = #txteffect#
FontEffectColor = #txteffectcolor#
AntiAlias = 0
Prefix = #dotpt#
ClipString = #CPS#
ClipStringW = #CPSW#
ClipStringH = #CPSH#