Simon Fell > Its just code
Jake says the WinAmp API is pretty easy to use, I'll check it out, its got to be better than trawling the window titles
Radio Rocks !, As you can see, i succesfully completed my project to hook WinAmp and Radio today, I wrote up the details if you want to see just how extensible Radio is.
yes ! it worked <vbg>
ok, so now we have (this is just inline inside the item template)
<%
local (adrblog = radio.weblog.init ());
local (adrposts = @adrblog^.posts);
local (postNum = "<%paddedItemNum%>" ) ;
local (adrpost = @adrposts^.[postNum]) ;
local (tunz = "[no music !]" ) ;
if defined ( adrpost^.tunz )
{
tunz = adrpost^.tunz ;
};
return tunz ;
%>
Just need to hook the post/edit stuff now and create the extra field
that was painful, but here's the script to pull out an additional item from the webLogData posts table
<%
local (adrblog = radio.weblog.init ());
local (adrposts = @adrblog^.posts);
local (postNum = "<%paddedItemNum%>" ) ;
local (adrpost = @adrposts^.[postNum]) ;
return adrpost^.tunz ;
%>
Todo
(i) Hook the edit/creation of posts to record the results of calling the DLL
(ii) Gracefully handle all the previous posts with no .tunz field
BTW, I wrote a little external DLL for Radio that gets you the current song from WinAmp. Its a pretty painless exercise, and makes the expansion possibilities for Radio almost limitless :). Here's the docs for writing external DLL's
Ahhh, i was sooo close. Hmmm, the item template gets applied to each item at render time, not at creation time. back to the docs.
PocketSOAP 1.2.2 hits the streets.
Starting the process of getting 4s4c 2.0 to do the right things, its starting to come together