I have 30,000 plus virtual radios that I have given out for free that have stopped working because of this.
How do I fix 30,000 radios if I can't remotely update the scripts in them.
It took me a few hours to find the cause here in this thread. Info and script as follows:
This music URL hover text script has worked for almost 10 years in the over 30,000 free radios I have given out for IndieSpectrum Radio.
It now returns a script error of: URL passed to llHTTPRequest contains a control character.
It does this on any Shoutcast stream URL that I have tried, not just my own which is http://indiespectrum.com:9000
It does this on three different sims
And it does it with both Firestorm and the stock LL viewer
I can't see how all the shoutcast servers changed how they send the now playing string.
Any help would be greatly appreciated as I run my station at a loss just to promote live music in SL.
Thank you in advance, Fox Reinsch
==================================
Script (with a different Internet station URL from mine):
==================================
// leave music_url blank if set in object's description
string music_url = "http://78.46.91.38:8000";
key HTTPRequest;
string feed;
string URL;
string currSongTitle;
string lastSongTitle;
list feedList;
default
{
state_entry()
{
llSetText(" ",<1,1,1>,1);
llSetTimerEvent(5.0);
if(music_url)
{
URL = music_url;
} else {
URL = llGetObjectDesc();
}
}
timer()
{
HTTPRequest=llHTTPRequest(URL + "/7.html HTTP/1.0\nUser-Agent: LSL Script (Mozilla Compatible)\n\n",[],"");
}
http_response(key k,integer status, list meta, string body)
{
if(k != HTTPRequest) return;
feed = llGetSubString(body,llSubStringIndex(body, "<body>") + llStringLength("<body>"), llSubStringIndex(body,"</body>") - 1);
feedList = llParseString2List(feed,[","],[]);
currSongTitle = llList2String(feedList,6);
integer length = llGetListLength(feedList);
if(llList2String(feedList,7))
{
integer a = 7;
for(; a<length; ++a)
{
currSongTitle += ", " + llList2String(feedList,a);
}
}
if (currSongTitle != lastSongTitle)
{
llSetText ("Now playing on IndieSpectrum Radio \n"+currSongTitle,<1,1,1>,0.75);
lastSongTitle = currSongTitle;
}
}
}