It is currently July 15th, 2020, 11:32 am

Football (soccer...) skin

Help with creating, editing & fixing problems with skins
tom0711
Posts: 36
Joined: April 29th, 2020, 5:55 pm

Re: Football (soccer...) skin

Post by tom0711 »

How do I know if a site uses java?
User avatar
balala
Rainmeter Sage
Posts: 11036
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: Football (soccer...) skin

Post by balala »

tom0711 wrote:
May 22nd, 2020, 7:37 pm
How do I know if a site uses java?
Basically I'm checking its source code and look there for the javascript expression. If you find it, the site uses those scripts, otherwise it doesn't.
There could be more accurate procedures, but I think this does work in most cases.
tom0711
Posts: 36
Joined: April 29th, 2020, 5:55 pm

Re: Football (soccer...) skin

Post by tom0711 »

I haven't found any info source that doesn't use javascript,hope you'll still succeed.
User avatar
balala
Rainmeter Sage
Posts: 11036
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: Football (soccer...) skin

Post by balala »

tom0711 wrote:
May 22nd, 2020, 8:45 pm
I haven't found any info source that doesn't use javascript,hope you'll still succeed.
For instance this is a source which looks to be alright: https://int.soccerway.com/teams/england/manchester-city-football-club/676/. I think it can be used. But probably it shows only the results of Manchester City?
But just a quick code, which returns the result of the first match (for now, only of the first match). If it's ok, further information can be added, but first please check the code:

Code: Select all

[Rainmeter]
Update=1000
DynamicWindowSize=1

[Variables]


[MeasureRainmeter]
Measure=WebParser
UpdateRate=870
Url=https://int.soccerway.com/teams/england/manchester-city-football-club/676/
RegExp=(?siU)<td class="team team-a ">.*<a href="/teams.*/" title=".*">(.*)</a>.*(\d{1,2}) - (\d{1,2}).*<a href="/teams.*/" title=".*">(.*)</a>

[MeasureTeam1]
Measure=WebParser
Url=[MeasureRainmeter]
StringIndex=1
RegExpSubstitute=1
Substitute="\n":"","\s{2,}":""

[MeasureTeam2]
Measure=WebParser
Url=[MeasureRainmeter]
StringIndex=4
RegExpSubstitute=1
Substitute="\n":"","\s{2,}":""

[MeasureResult1]
Measure=WebParser
Url=[MeasureRainmeter]
StringIndex=2

[MeasureResult2]
Measure=WebParser
Url=[MeasureRainmeter]
StringIndex=3

[MeterResult]
Meter=STRING
MeasureName=MeasureTeam1
MeasureName2=MeasureTeam2
MeasureName3=MeasureResult1
MeasureName4=MeasureResult2
X=0
Y=0
Padding=15,5,15,5
FontColor=220,220,220
FontEffectColor=0,0,0
StringEffect=Shadow
SolidColor=0,0,0,150
FontSize=8
FontFace=Segoe UI
StringStyle=BOLD
StringAlign=LEFT
AntiAlias=1
Text=%1 - %2#CRLF#%3 - %4
DynamicVariables=1
So, what do you think?
dvo
Posts: 818
Joined: February 7th, 2016, 6:08 am

Re: Football (soccer...) skin

Post by dvo »

i think Toma0711,
will be happy with the start because he asked the same on :
https://www.reddit.com/r/Rainmeter/comments/gn94s3/football_soccer_skin/
with the same awnser ...a lot of work...

(old skins are already dead)
Last edited by dvo on May 23rd, 2020, 8:04 pm, edited 2 times in total.
tom0711
Posts: 36
Joined: April 29th, 2020, 5:55 pm

Re: Football (soccer...) skin

Post by tom0711 »

if info like other teams and date&time will be added it will be fantastic,but looks good thanks
You do not have the required permissions to view the files attached to this post.
User avatar
balala
Rainmeter Sage
Posts: 11036
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: Football (soccer...) skin

Post by balala »

tom0711 wrote:
May 23rd, 2020, 7:02 pm
if info like other teams and date&time will be added it will be fantastic,but looks good thanks
Alright, I'm gonna work with it a little bit, but this only tomorrow, since here is almost midnight, and I'm not working anymore tonight. :thumbup:
Stay tuned if interested.
tom0711
Posts: 36
Joined: April 29th, 2020, 5:55 pm

Re: Football (soccer...) skin

Post by tom0711 »

No problem,here it already midnight, all good
dvo
Posts: 818
Joined: February 7th, 2016, 6:08 am

Re: Football (soccer...) skin

Post by dvo »

balala,

found a paste /bin online maybe this helps....

Code: Select all

[Rainmeter]
Update=1000

; = = = = = MEASURES = = = = =

[Team1]
Measure=WebParser
URL="https://www.premierleague.com/tables"
RegExp=(?siU)tablebodyContainer.*span class="long">(.*)</span.*<t.*>(.*)</.*<t.*>(.*)</.*<t.*>(.*)</.*<t.*>(.*)</.*<t.*>(.*)</.*<t.*>(.*)</.*<t.*>..........(.*)</.*<t.*>(.*)</
StringIndex=1

[Played1]
Measure=WebParser
URL=[Team1]
StringIndex=2

[Won1]
Measure=WebParser
URL=[Team1]
StringIndex=3

[Drawn1]
Measure=WebParser
URL=[Team1]
StringIndex=4

[Lost1]
Measure=WebParser
URL=[Team1]
StringIndex=5

[GF1]
Measure=WebParser
URL=[Team1]
StringIndex=6

[GA1]
Measure=WebParser
URL=[Team1]
StringIndex=7

[GD1]
Measure=WebParser
URL=[Team1]
StringIndex=8

[Points1]
Measure=WebParser
URL=[Team1]
StringIndex=9

; = = = = = METERS = = = = =

[TextTeam1]
Meter=String
MeasureName=Team1
FontSize=21
FontColor=0, 0, 0, 255
AntiAlias=1
X=0
Y=0
W=300
H=60
Text=%1

[TextPlayed1]
Meter=String
MeasureName=Played1
FontSize=21
FontColor=0, 0, 0, 255
AntiAlias=1
X=140
Y=0
W=300
H=60
Text=%1

[TextWon1]
Meter=String
MeasureName=Won1
FontSize=21
FontColor=0, 0, 0, 255
AntiAlias=1
X=180
Y=0
W=300
H=60
Text=%1

[TextDrawn1]
Meter=String
MeasureName=Drawn1
FontSize=21
FontColor=0, 0, 0, 255
AntiAlias=1
X=220
Y=0
W=300
H=60
Text=%1

[TextLost1]
Meter=String
MeasureName=Lost1
FontSize=21
FontColor=0, 0, 0, 255
AntiAlias=1
X=260
Y=0
W=300
H=60
Text=%1

[TextGF1]
Meter=String
MeasureName=GF1
FontSize=21
FontColor=0, 0, 0, 255
AntiAlias=1
X=300
Y=0
W=300
H=60
Text=%1

[TextGA1]
Meter=String
MeasureName=GA1
FontSize=21
FontColor=0, 0, 0, 255
AntiAlias=1
X=340
Y=0
W=300
H=60
Text=%1

[TextGD1]
Meter=String
MeasureName=GD1
FontSize=21
FontColor=0, 0, 0, 255
AntiAlias=1
X=380
Y=0
W=300
H=60
Text=%1

[TextPoints1]
Meter=String
MeasureName=Points1
FontSize=21
FontColor=0, 0, 0, 255
AntiAlias=1
X=450
Y=0
W=300
H=60
Text=%1
User avatar
balala
Rainmeter Sage
Posts: 11036
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: Football (soccer...) skin

Post by balala »

dvo wrote:
May 24th, 2020, 6:08 am
found a paste /bin online maybe this helps....
No, I think it doesn't. The same URL posted by you, was tom0711's second choice and didn't help, because all those sites are using java scripts. Otherwise after a quick check, it seems the code you posted doesn't work, doesn't return anything.