Lyricator - Batch Lyrics Updater v1.00 [OUTDATED]

Download and get help for different MediaMonkey for Windows 4 Addons.

Moderators: Peke, Gurus

Semmetju
Posts: 13
Joined: Sat Aug 14, 2010 7:05 am

Re: Lyricator - Batch Lyrics Updater v1.00 [MM3]

Post by Semmetju »

What we need to do is retrieve this url: "http://www.lyricsplugin.com/winamp03/pl ... No%20Limit"
Which contains this source code:

Code: Select all

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
    <meta http-equiv="content-type" content="text/html; charset=UTF-8" />
    <link rel="stylesheet" type="text/css" href="http://www.lyricsplugin.com/winamp03/css/plugin.css" />
    <script language="javascript" type="text/javascript" src="http://www.lyricsplugin.com/winamp03/javascript/plugin.js"></script>
    <script language="javascript" type="text/javascript" src="http://www.lyricsplugin.com/winamp03/plugin/content.js"></script>
</head>
<body onload="javascript:getContent('2%20Unlimited', 'No%20Limit', '1281787161', '57e3560a92d91d00754b6a1ddbf3c453')">
<div id="content">

<div id="title">
&nbsp;
</div>

<div id="artist">
&nbsp;
</div>

<div id="lyrics">
<a href="http://www.lyricsvip.com/" target="_blank">http://www.lyricsvip.com</a>
</div>

</div>
</body>
</html>
The source for the getContent function is this:

Code: Select all

function getContent(artist, title, time, check)
{ 
    xmlHttp = GetXmlHttpObject();
    if(xmlHttp == null)
     {
        return;
     }
    var url = "content.php?artist=" + artist + "&title=" + title + "&time=" + time + "&check=" + check;
    xmlHttp.onreadystatechange = stateChanged;
    xmlHttp.open("GET", url, true);
    xmlHttp.send(null);
}
So our url will become http://www.lyricsplugin.com/winamp03/pl ... 9132c3734b

And we will have to automate all this...

EDIT: And ofcourse the referer has to be correct.
ripken204
Posts: 11
Joined: Tue Aug 10, 2010 1:29 am

Re: Lyricator - Batch Lyrics Updater v1.00 [MM3]

Post by ripken204 »

that lyrics site no longer works though, that is the problem.
correct me if i am wrong.
Guest

Re: Lyricator - Batch Lyrics Updater v1.00 [MM3]

Post by Guest »

ripken204 wrote:that lyrics site no longer works though, that is the problem.
correct me if i am wrong.
Yeah it does ;)
http://www.lyricsplugin.com/winamp03/pl ... 0Unlimited
Semmetju
Posts: 13
Joined: Sat Aug 14, 2010 7:05 am

Re: Lyricator - Batch Lyrics Updater v1.00 [MM3]

Post by Semmetju »

Guest wrote:
ripken204 wrote:that lyrics site no longer works though, that is the problem.
correct me if i am wrong.
Yeah it does ;)
http://www.lyricsplugin.com/winamp03/pl ... 0Unlimited
They just added extra security, don't ask me why... :(
Semmetju
Posts: 13
Joined: Sat Aug 14, 2010 7:05 am

Re: Lyricator - Batch Lyrics Updater v1.00 [MM3]

Post by Semmetju »

Getting close to getting this baby to work, just some more debugging to do with WireShark... :D
guest

Re: Lyricator - Batch Lyrics Updater v1.00 [MM3]

Post by guest »

If you want to post your progress, I'd be happy to help. I was working on it just last night building samples with wireshark, analyzing packets from the WMP plugin to see if I could determine the naming conventions they used. I'm just a bit sketchy on the javascript end (haven't written anything in that since college). There was one packet sent each time that had me a bit stumped, perhaps an authentication, or maybe just a checksum for the files, I don't know, nothing it's nothing significant. If you've overcome any of that, this could be getting close. If not, it may be easier to use another source API.
Vyper
Posts: 845
Joined: Tue May 23, 2006 5:53 pm

Re: Lyricator - Batch Lyrics Updater v1.00 [MM3]

Post by Vyper »

Has anyone touched base with Owyn since this is essentially his script now?
Stop Button Freak
trixmoto
Posts: 10024
Joined: Fri Aug 26, 2005 3:28 am
Location: Hull, UK
Contact:

Re: Lyricator - Batch Lyrics Updater v1.00 [MM3]

Post by trixmoto »

I certainly got the impression from him that he was working on a new version...
Owyn wrote:I know what the problem is, the response now uses an onload event. However, I still don't know how to solve it. Back to RTFM and testing.
We discussed a few solutions after this so I assumed he was trying them out.
Download my scripts at my own MediaMonkey fansite.
All the code for my website and scripts is safely backed up immediately and for free using Dropbox.
Semmetju
Posts: 13
Joined: Sat Aug 14, 2010 7:05 am

Re: Lyricator - Batch Lyrics Updater v1.00 [MM3]

Post by Semmetju »

Hey guys, i can't work on this right now cause i've been drinking :lol: cant really focus right now. I believe the only problem left is the referer header. Check it out.
http://pastebin.com/wK2TTTR7
Semmetju
Posts: 13
Joined: Sat Aug 14, 2010 7:05 am

Re: Lyricator - Batch Lyrics Updater v1.00 [MM3]

Post by Semmetju »

Hmm,
Looks like a bug in MooTools or something.
Can't get it to set the Referer header, it just shows up blank in wireshark.

Removed a sloppy workaround:
http://pastebin.com/FNFm3LY9
Semmetju
Posts: 13
Joined: Sat Aug 14, 2010 7:05 am

Re: Lyricator - Batch Lyrics Updater v1.00 [MM3]

Post by Semmetju »

Seems like the bug lies even deeper... :(
MooTools adds all the headers nicely, but somehow they just wont show up properly.
Does anyone have any experience with this?
Semmetju
Posts: 13
Joined: Sat Aug 14, 2010 7:05 am

Re: Lyricator - Batch Lyrics Updater v1.00 [MM3]

Post by Semmetju »

We're screwed... :(

Take a look here:
http://support.microsoft.com/kb/178066
Specifically this part:
The Referer header also will not be sent when the link is from a non-HTTP(S) protocol, such as file://, to another page.
*Sigh*
How are we gonna fix this?
Semmetju
Posts: 13
Joined: Sat Aug 14, 2010 7:05 am

Re: Lyricator - Batch Lyrics Updater v1.00 [MM3]

Post by Semmetju »

Ok, guys.
All we need now is a favor from someone who is willing to upload this php script to his server...
http://pastebin.com/tUKaSAHJ

And then adjust this script accordingly (changing the http://www.somewebserver.com/get.php part to the correct URL)
http://pastebin.com/nqxfLw1D

I just tried it on my homeserver and it is working 100% :D
nynaevelan
Posts: 5559
Joined: Wed Feb 07, 2007 11:07 pm
Location: New Jersey, USA
Contact:

Re: Lyricator - Batch Lyrics Updater v1.00 [MM3]

Post by nynaevelan »

Vyper wrote:Has anyone touched base with Owyn since this is essentially his script now?
I agree, this is an active script with an active scripter, should it be taken over by someone else without his knowledge or consent??
3.2x - Win7 Ultimate (Zen Touch 2 16 GB/Zen 8GB)
Link to Favorite Scripts/Skins

Join Dropbox, the online site to share your files
Semmetju
Posts: 13
Joined: Sat Aug 14, 2010 7:05 am

Re: Lyricator - Batch Lyrics Updater v1.00 [MM3]

Post by Semmetju »

nynaevelan wrote:
Vyper wrote:Has anyone touched base with Owyn since this is essentially his script now?
I agree, this is an active script with an active scripter, should it be taken over by someone else without his knowledge or consent??
I just fixed it cause I needed it for myself.
This is meant to be just a quick fix, and if Owyn wants to use my stuff, he is free to do so...
Locked