My project is when Pandora is open and playing, be able to punch a button (either on the page or as an add-on in Firefox. This button would then activate a script that would pull the song and artist name from the page and store them in variables. Then these strings would be put through a Youtube search. The URL of the first video will then be stored in another variable. A website that strips the mp3 from the video will be opened and the Youtube URL will be deposited in the appropriate field. Ideally the converted file will then be downloaded.
I don't know much Javascript but the point of this project is to help me learn. I haven't gotten very far at all and need some help. I know the divs where the song string is on the page but can't seem to store it. I'm using GreaseMonkey to run the script.
One suggestion was to use Java and make it a desktop application and have it listen to system volume and send it to a Shazam-like website and go from there but there are no non-mobile Shazam apps that would apply to this.
What I need help with:
Is JS the right language to use for this task? If so: How do I store the song info into variables. I've researched it and anything I put into the script involving a variable causes it to not run.
Thanks in advance.