I sent an e-mai to Flavio - lyrdb developer and he was very kind to send me response with detailed explanation and proposed solution which should be implemented in plug-in.
Meanwhile I've renamed the artist name to change "&" to "and" - I don't know when lyrics plug-in's developer is going to make this change if at all. I'll try to communicate with hime directly. Here is the response from Flavio >Flavio González Vázquez wrote: > > The issue you are reporting is a escaping problem by the squeezebox plugin. It is true that when you look for "Simon & Garfunkel" you get songs of "Carly Simon" (I have checked it), but that is because the ampersand is a metacharacter in URLs, as it is used to split the parameters in the URL. The URL that is being called by the plug-in is: > > http://webservices.lyrdb.com/lookup.php?q=Simon & Garfunkel&for=fullt > > In this way, the query ("q" parameter) would only contain "Simon" and the ampersand "&" would start a new parameter "Garfunkel" without a value, that is ignored by the script because it is unknown. That's why it return the wrong artist, as it doesn't include the "Garfunkel" keyword at all. > > The solution is to escape the ampersand as "%26", and then the URL may look like this: > > http://webservices.lyrdb.com/lookup.php?q=Simon %26 Garfunkel&for=fullt > > Now it returns both "Simon & Garfunkel" and "Simon And Garfunkel" songs, even "Simon & Garfunkel (Paul Simon & Art Garfunkel)" (check it by yourself by clicking on the right URL (the last one with the ampersand escaped). > > The conclusion is that you must escape any non-alphanumeric character you pass to the script. As I am not the developer of the squeezebox plugin, you may tell the developer to do that, but this is not very difficult to do, as it may only take 1 minute to accomplish ;-) > > I hope you don't have to rename artists again, as this is not your fault and the database must return you the right songs whatever version of the artist name you provide! > > Regards, > Flavio -- sl789 ------------------------------------------------------------------------ sl789's Profile: http://forums.slimdevices.com/member.php?userid=5667 View this thread: http://forums.slimdevices.com/showthread.php?t=50583
_______________________________________________ plugins mailing list plugins@lists.slimdevices.com http://lists.slimdevices.com/lists/listinfo/plugins