It is currently April 13th, 2024, 2:46 am

Astronomy Photo of the Day Webparser help

Get help with creating, editing & fixing problems with skins
Squir3l
Posts: 2
Joined: August 6th, 2010, 9:09 am

Astronomy Photo of the Day Webparser help

Post by Squir3l »

I was trying to make a simple skin that would show the title and photo of the day from the Astronomy Photo of the Day website:

http://antwrp.gsfc.nasa.gov/apod/

rss:

http://antwrp.gsfc.nasa.gov/apod.rss

I thought I might be able to do this, but I just got so overwhelmed and confused with all the WebParser stuff. I know this should be very easy, I'm just a newb when it comes to programing and just figuring out the normal rainmeter stuff is my limit right now. ;-)

If anyone would be willing to help me, I would be very grateful. Thanks in advance!
User avatar
kenz0
Developer
Posts: 263
Joined: July 31st, 2009, 2:23 pm
Location: Tokyo, JPN

Re: Astronomy Photo of the Day Webparser help

Post by kenz0 »

I have actually made the skin which used this site a long time ago.

OK, here is a sample code.

Code: Select all

[Rainmeter]
DynamicWindowSize=1

[MeasureSource]
Measure=Plugin
Plugin=Plugins\WebParser.dll
UpdateRate=10800
Url=http://antwrp.gsfc.nasa.gov/apod/
RegExp="(?siU)<IMG SRC=\"(.*)\".*<b>(.*)<"

[MeasurePhoto]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=http://antwrp.gsfc.nasa.gov/[MeasureSource]
StringIndex=1
Download=1

[MeasureTitle]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureSource]
StringIndex=2

[MeaterImage]
Meter=IMAGE
MeasureName=MeasurePhoto
X=0
Y=0

[MeterTitle]
Meter=STRING
MeasureName=MeasureTitle
X=10
Y=10
FontColor=FFFFFFCC
SolidColor=000000CC
FontSize=12
AntiAlias=1
.
Image
Squir3l
Posts: 2
Joined: August 6th, 2010, 9:09 am

Re: Astronomy Photo of the Day Webparser help

Post by Squir3l »

Cool, I knew it would be easy for someone else. Thank you very much.