It is currently March 29th, 2024, 1:02 pm

[Bug] "Download=1" causes an RegExp Error

Get help with creating, editing & fixing problems with skins
Jus
Posts: 6
Joined: January 15th, 2017, 8:09 pm

[Bug] "Download=1" causes an RegExp Error

Post by Jus »

If i write down Download=1 under the it causes RegExp error in the log, and even if i remove the "Download=1" it keeps saying it is a RegExp error.
If i unload and load it again it just says: Unable to open:

Code: Select all

[Rainmeter]
Update=1000
AccurateText=1
DynamicWindowSize=1

[MeterBackround]
Meter=Image
H=400
W=400
SolidColor=15,15,15

[PMeasureTitleYCColdmirror]
Measure=Plugin
Plugin=WebParser
URL=https://www.youtube.com/user/coldmirror
RegExp=(?siU) <h3 class="yt-lockup-title "><a class=".*" dir="ltr" title="(.*)"  aria-describedby.*<h3 class="yt-lockup-title "><a class=".*" dir="ltr" title="(.*)"  aria-describedby

[CMeasureTitleYCColdmirror1]
Measure=Plugin
Plugin=WebParser
URL=[PMeasureTitleYCColdmirror]
StringIndex=1

[CMeasureTitleYCColdmirror2]
Measure=Plugin
Plugin=WebParser
URL=[PMeasureTitleYCColdmirror]
StringIndex=2

[CMeterTitleYCColdmirror1]
Meter=String
MeasureName=CMeasureTitleYCColdmirror1
X=5
Y=0
W=280
H=15
StringAlign=Left
FontSize=8
FontColor=252,251,202,255
SolidColor=0,0,0,1
Padding=5,5,5,5
AntiAlias=1

[CMeterTitleYCColdmirror2]
Meter=String
MeasureName=CMeasureTitleYCColdmirror2
X=5
Y=200
W=280
H=15
FontSize=8
FontColor=252,251,202,255
SolidColor=0,0,0,1
Padding=5,5,5,5
AntiAlias=1


////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////


[PMeasureZeitYCColdmirror]
Measure=Plugin
Plugin=WebParser
URL=https://www.youtube.com/user/coldmirror
RegExp=(?siU)<ul class=".*".*Aufrufe</li><li>(.*)</li>.*<ul class=".*".* Aufrufe</li><li>(.*)</li>

[CMeasureZeitYCColdmirror1]
Measure=Plugin
Plugin=WebParser
URL=[PMeasureZeitYCColdmirror]
StringIndex=1

[CMeasureZeitYCColdmirror2]
Measure=Plugin
Plugin=WebParser
URL=[PMeasureZeitYCColdmirror]
StringIndex=2

[CMeterZeitYCColdmirror1]
Meter=String
MeasureName=CMeasureZeitYCColdmirror1
X=5
Y=10
W=280
H=15
StringAlign=Left
FontSize=8
FontColor=252,251,202,255
SolidColor=0,0,0,1
Padding=5,5,5,5
AntiAlias=1

[CMeterZeitYCColdmirror2]
Meter=String
MeasureName=CMeasureZeitYCColdmirror2
X=5
Y=210
W=280
H=15
FontSize=8
FontColor=252,251,202,255
SolidColor=0,0,0,1
Padding=5,5,5,5
AntiAlias=1


////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

[PMeasureImageYCColdmirror]
Measure=Plugin
Plugin=WebParser
URL=https://www.youtube.com/user/coldmirror/videos
RegExp=(?siU)<span class="yt-thumb-default">.*<span class="yt-thumb-clip">.*<img src="(.*)".*<span class="yt-thumb-default">.*<span class="yt-thumb-clip">.*<img src="(.*)"

[CMeasureImageYCColdmirror1]
Measure=Plugin
Plugin=WebParser
URL=[PMeasureImageYCColdmirror]
StringIndex=1
Download=1

[CMeasureImageYCColdmirror2]
Measure=Plugin
Plugin=WebParser
URL=[PMeasureImageYCColdmirror]
StringIndex=2
Download=1

[CMeterImageYCColdmirror1]
Meter=Image
MeasureName=CMeasureImageYCColdmirror1
X=5
Y=20
W=280
H=15
StringAlign=Left
FontSize=8
FontColor=252,251,202,255
SolidColor=0,0,0,1
Padding=5,5,5,5
AntiAlias=1

[CMeterImageYCColdmirror2]
Meter=Image
MeasureName=CMeasureImageYCColdmirror2
X=5
Y=220
W=280
H=15
FontSize=8
FontColor=252,251,202,255
SolidColor=0,0,0,1
Padding=5,5,5,5
AntiAlias=1




User avatar
eclectic-tech
Rainmeter Sage
Posts: 5384
Joined: April 12th, 2012, 9:40 pm
Location: Cedar Point, Ohio, USA

Re: [Bug] "Download=1" causes an RegExp Error

Post by eclectic-tech »

This code will work.. modified the RegExp, moved Download=1 to the child measures, and updated the image meters when the child measures are finished.

Code: Select all

[PMeasureImageYCColdmirror]
Measure=Plugin
Plugin=WebParser
URL=https://www.youtube.com/user/coldmirror/videos
RegExp=(?siU).*<span class="yt-thumb-default">.*<span class="yt-thumb-clip">.* src="(.*)\?custom.*<span class="yt-thumb-clip">.* src="(.*)\?custom.*
ForceReload=1

[CMeasureImageYCColdmirror1]
Measure=Plugin
Plugin=WebParser
URL=[PMeasureImageYCColdmirror]
StringIndex=1
Download=1
FinishAction=[!UpdateMeter MeterImage1]

[CMeasureImageYCColdmirror2]
Measure=Plugin
Plugin=WebParser
URL=[PMeasureImageYCColdmirror]
StringIndex=2
Download=1
FinishAction=[!UpdateMeter MeterImage2]

[CMeterImageYCColdmirror1]
Meter=String
MeasureName=CMeasureImageYCColdmirror1
X=5
Y=20
W=380
H=15
StringAlign=Left
FontSize=12
FontColor=252,251,202,255
SolidColor=0,0,0,1
Padding=5,5,5,5
AntiAlias=1

[MeterImage1]
Meter=Image
X=r
Y=R
W=
H=
MeasureName=CMeasureImageYCColdmirror1

[CMeterImageYCColdmirror2]
Meter=String
MeasureName=CMeasureImageYCColdmirror2
X=r
Y=R
W=280
H=15
FontSize=12
FontColor=252,251,202,255
SolidColor=0,0,0,1
Padding=5,5,5,5
AntiAlias=1

[MeterImage2]
Meter=Image
X=r
Y=R
W=
H=
MeasureName=CMeasureImageYCColdmirror2
images2.png
You do not have the required permissions to view the files attached to this post.
Jus
Posts: 6
Joined: January 15th, 2017, 8:09 pm

Re: [Bug] "Download=1" causes an RegExp Error

Post by Jus »

Oh thanks!
Sry for calling it a bug i am not to much into rainmeter.
That helps a lot.
User avatar
eclectic-tech
Rainmeter Sage
Posts: 5384
Joined: April 12th, 2012, 9:40 pm
Location: Cedar Point, Ohio, USA

Re: [Bug] "Download=1" causes an RegExp Error

Post by eclectic-tech »

You're welcome. :welcome:

No problem , it was a 'Bug' for you! :)

The 2 issues you had were:
The question mark is a reserved character in RegExp and needed to be escaped to end the capture, and Download=1 option needed to be on the measure with the URL address.

Glad to help!