I was so inspired by unhappyelf's use of a PHP to PNG Live Stats Signature, that I decided to take it another step and write my own Windows Gadget to display the PNG we created on my desktop. This gives me a nice gadget I can make transparent and easily check on the status of all my folding clients.
This is the first revision, and hopefully I'll get better at coding in some settings tabs to make the install easier, but I wanted to get this in your hands as soon as possible to get some feedback / help finishing it.
This will be the end result:
1. Find the dimension of your Folding Signature PNG you created following
Unhappy Elf's Tutorial. You can do this by navigating to your signature directly, right clicking it and selecting properties. This will pop open a dialog box and show you the dimensions. Write this down, you'll need it later.
2.
Download the LiveFolding.zip. Extract and double click LiveFolding.gadget to install.
3. Navigate to the path of the installed gadget.
Quick Trick: Copy the line below and paste it into your run box.
%localappdata%\Microsoft\Windows Sidebar\Gadgets\LiveFolding.gadget
4. You should now see 3 files:
Gadget.xml
LiveGadget.html
LiveGadget.png
5. Right Click LiveGadget.html and select
"Open With -> Choose Program" and select
Notepad from the list of applications.
6.
Edit Line 3. Below is an example. You will want to change the
red value below to your User Account Login.
<meta http-equiv="refresh" content="900;url=C:\Users\
USERNAME\AppData\Local\Microsoft\Windows Sidebar\Gadgets\LiveFolding.gadget\LiveGadget.html" />
7.
Edit Line 5. Below is an example. You will want to change the
Height and
Width values in red to match your PNG's dimensions.
<body style="margin:0px; padding=0; width:
900px; height:
181px;">
8.
Edit Line 6. Below is an example. You will want to change the source path (URL) in blue to point to your live stats PNG (full URL).
<iframe src="
http://alphaserver.game-s...olding/Livefolding.png" marginheight="0" marginwidth="0" style="width:100%; height:100%" scrolling="no" allowtransparency="true" frameborder="0"></iframe>
9. Save your changes and close notepad and the windows explorer window.
10. Right click on your desktop and select Gadgets.
11. Select the
Live Folding Stats gadget and drag it to your desktop.
12. Enjoy!
Some more information: If you want the gadget to be more transparent, you can right click it and select
Opacity level to your liking.
The gadget is coded to update itself (refresh the PNG image) once every 15 minutes. If you would like to modify this time (faster or slower) you can do so in the file
LiveGadget.html. You will need to modify
Line 3 and change the
900 in the section
content='900; This sets the timeout to refresh in seconds, so for one minute change 900 to 60, two minutes would be 120, etc.
UPDATE: I was able to get the gadget to be self installing so this cut out a few steps. Now all you have to do is double click LiveFolding.gadget to install (found inside Livefolding.zip).
post edited by Tiger770 - 2011/02/02 18:41:46